0
0
mirror of https://github.com/vim/vim.git synced 2025-09-25 03:54:15 -04:00

patch 8.0.0425: build errors when building without folding

Problem:    Build errors when building without folding.
Solution:   Add #ifdefs. (John Marriott)
This commit is contained in:
Bram Moolenaar
2017-03-05 21:18:27 +01:00
parent f7e894dfb6
commit a6c07603ca
5 changed files with 15 additions and 7 deletions

View File

@@ -2616,7 +2616,6 @@ diff_get_corresponding_line(buf_T *buf1, linenr_T lnum1)
return lnum; return lnum;
} }
#if defined(FEAT_FOLDING) || defined(PROTO)
/* /*
* For line "lnum" in the current window find the equivalent lnum in window * For line "lnum" in the current window find the equivalent lnum in window
* "wp", compensating for inserted/deleted lines. * "wp", compensating for inserted/deleted lines.
@@ -2656,6 +2655,5 @@ diff_lnum_win(linenr_T lnum, win_T *wp)
n = dp->df_lnum[i] + dp->df_count[i]; n = dp->df_lnum[i] + dp->df_count[i];
return n; return n;
} }
#endif
#endif /* FEAT_DIFF */ #endif /* FEAT_DIFF */

View File

@@ -541,8 +541,8 @@ edit(
/* /*
* Handle restarting Insert mode. * Handle restarting Insert mode.
* Don't do this for "CTRL-O ." (repeat an insert): we get here with * Don't do this for "CTRL-O ." (repeat an insert): In that case we get
* restart_edit non-zero, and something in the stuff buffer. * here with something in the stuff buffer.
*/ */
if (restart_edit != 0 && stuff_empty()) if (restart_edit != 0 && stuff_empty())
{ {
@@ -1453,10 +1453,14 @@ doESCkey:
docomplete: docomplete:
compl_busy = TRUE; compl_busy = TRUE;
#ifdef FEAT_FOLDING
disable_fold_update++; /* don't redraw folds here */ disable_fold_update++; /* don't redraw folds here */
#endif
if (ins_complete(c, TRUE) == FAIL) if (ins_complete(c, TRUE) == FAIL)
compl_cont_status = 0; compl_cont_status = 0;
#ifdef FEAT_FOLDING
disable_fold_update--; disable_fold_update--;
#endif
compl_busy = FALSE; compl_busy = FALSE;
break; break;
#endif /* FEAT_INS_EXPAND */ #endif /* FEAT_INS_EXPAND */

View File

@@ -4535,8 +4535,11 @@ do_set(
* "wrap" gets set. */ * "wrap" gets set. */
if (curwin->w_p_diff if (curwin->w_p_diff
&& opt_idx >= 0 /* shut up coverity warning */ && opt_idx >= 0 /* shut up coverity warning */
&& (options[opt_idx].indir == PV_FDM && (
|| options[opt_idx].indir == PV_WRAP)) #ifdef FEAT_FOLDING
options[opt_idx].indir == PV_FDM ||
#endif
options[opt_idx].indir == PV_WRAP))
goto skip; goto skip;
#endif #endif
} }

View File

@@ -1183,11 +1183,12 @@ syn_stack_free_block(synblock_T *block)
void void
syn_stack_free_all(synblock_T *block) syn_stack_free_all(synblock_T *block)
{ {
#ifdef FEAT_FOLDING
win_T *wp; win_T *wp;
#endif
syn_stack_free_block(block); syn_stack_free_block(block);
#ifdef FEAT_FOLDING #ifdef FEAT_FOLDING
/* When using "syntax" fold method, must update all folds. */ /* When using "syntax" fold method, must update all folds. */
FOR_ALL_WINDOWS(wp) FOR_ALL_WINDOWS(wp)

View File

@@ -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 */
/**/
425,
/**/ /**/
424, 424,
/**/ /**/