forked from aniani/vim
patch 8.0.0461: test 45 hangs on MS-Windows
Problem: Test 45 hangs on MS-Windows. Solution: Reset 'shiftwidth'. Also remove redundent function.
This commit is contained in:
13
src/fold.c
13
src/fold.c
@@ -64,7 +64,6 @@ static void deleteFoldMarkers(fold_T *fp, int recursive, linenr_T lnum_off);
|
|||||||
static void foldDelMarker(linenr_T lnum, char_u *marker, int markerlen);
|
static void foldDelMarker(linenr_T lnum, char_u *marker, int markerlen);
|
||||||
static void foldUpdateIEMS(win_T *wp, linenr_T top, linenr_T bot);
|
static void foldUpdateIEMS(win_T *wp, linenr_T top, linenr_T bot);
|
||||||
static void parseMarker(win_T *wp);
|
static void parseMarker(win_T *wp);
|
||||||
static void foldMoveRange_int(garray_T *gap, linenr_T line1, linenr_T line2, linenr_T dest);
|
|
||||||
|
|
||||||
static char *e_nofold = N_("E490: No fold found");
|
static char *e_nofold = N_("E490: No fold found");
|
||||||
|
|
||||||
@@ -1076,12 +1075,6 @@ foldAdjustCursor(void)
|
|||||||
(void)hasFolding(curwin->w_cursor.lnum, &curwin->w_cursor.lnum, NULL);
|
(void)hasFolding(curwin->w_cursor.lnum, &curwin->w_cursor.lnum, NULL);
|
||||||
}
|
}
|
||||||
|
|
||||||
/* foldMoveRange() {{{2 */
|
|
||||||
void
|
|
||||||
foldMoveRange(garray_T *gap, linenr_T line1, linenr_T line2, linenr_T dest)
|
|
||||||
{
|
|
||||||
foldMoveRange_int(gap, line1, line2, dest);
|
|
||||||
}
|
|
||||||
/* Internal functions for "fold_T" {{{1 */
|
/* Internal functions for "fold_T" {{{1 */
|
||||||
/* cloneFoldGrowArray() {{{2 */
|
/* cloneFoldGrowArray() {{{2 */
|
||||||
/*
|
/*
|
||||||
@@ -2992,7 +2985,7 @@ foldReverseOrder(garray_T *gap, linenr_T start, linenr_T end)
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
/* foldMoveRange_int() {{{2 */
|
/* foldMoveRange() {{{2 */
|
||||||
/*
|
/*
|
||||||
* Move folds within the inclusive range "line1" to "line2" to after "dest"
|
* Move folds within the inclusive range "line1" to "line2" to after "dest"
|
||||||
* requires "line1" <= "line2" <= "dest"
|
* requires "line1" <= "line2" <= "dest"
|
||||||
@@ -3036,8 +3029,8 @@ truncate_fold(fold_T *fp, linenr_T end)
|
|||||||
#define valid_fold(fp, gap) ((fp) < ((fold_T *)(gap)->ga_data + (gap)->ga_len))
|
#define valid_fold(fp, gap) ((fp) < ((fold_T *)(gap)->ga_data + (gap)->ga_len))
|
||||||
#define fold_index(fp, gap) ((size_t)(fp - ((fold_T *)(gap)->ga_data)))
|
#define fold_index(fp, gap) ((size_t)(fp - ((fold_T *)(gap)->ga_data)))
|
||||||
|
|
||||||
static void
|
void
|
||||||
foldMoveRange_int(garray_T *gap, linenr_T line1, linenr_T line2, linenr_T dest)
|
foldMoveRange(garray_T *gap, linenr_T line1, linenr_T line2, linenr_T dest)
|
||||||
{
|
{
|
||||||
fold_T *fp;
|
fold_T *fp;
|
||||||
linenr_T range_len = line2 - line1 + 1;
|
linenr_T range_len = line2 - line1 + 1;
|
||||||
|
@@ -27,6 +27,7 @@ kYpj:call append("$", foldlevel("."))
|
|||||||
/^2 b
|
/^2 b
|
||||||
i jI :call append("$", "indent " . foldlevel("."))
|
i jI :call append("$", "indent " . foldlevel("."))
|
||||||
k:call append("$", foldlevel("."))
|
k:call append("$", foldlevel("."))
|
||||||
|
:set sw&
|
||||||
:" test syntax folding
|
:" test syntax folding
|
||||||
:set fdm=syntax fdl=0
|
:set fdm=syntax fdl=0
|
||||||
:syn region Hup start="dd" end="ii" fold contains=Fd1,Fd2,Fd3
|
:syn region Hup start="dd" end="ii" fold contains=Fd1,Fd2,Fd3
|
||||||
|
@@ -764,6 +764,8 @@ static char *(features[]) =
|
|||||||
|
|
||||||
static int included_patches[] =
|
static int included_patches[] =
|
||||||
{ /* Add new patch number below this line */
|
{ /* Add new patch number below this line */
|
||||||
|
/**/
|
||||||
|
461,
|
||||||
/**/
|
/**/
|
||||||
460,
|
460,
|
||||||
/**/
|
/**/
|
||||||
|
Reference in New Issue
Block a user