Patch 8.2.4928

8 views
Skip to first unread message

Bram Moolenaar

unread,
May 9, 2022, 4:05:53 PM5/9/22
to vim...@googlegroups.com

Patch 8.2.4928
Problem: Various white space and cosmetic mistakes.
Solution: Change spaces to tabs, improve comments.
Files: src/bufwrite.c, src/channel.c, src/cindent.c, src/crypt.c,
src/debugger.c, src/digraph.c, src/edit.c, src/evalwindow.c,
src/ex_cmds.c, src/ex_docmd.c, src/ex_getln.c, src/fileio.c,
src/filepath.c, src/gui.c, src/highlight.c, src/indent.c,
src/insexpand.c, src/job.c, src/keymap.h, src/macros.h,
src/menu.c, src/misc1.c, src/misc2.c, src/mouse.c, src/move.c,
src/normal.c, src/ops.c, src/option.c, src/option.h, src/search.c,
src/session.c, src/spellsuggest.c, src/structs.h, src/tag.c,
src/term.c, src/terminal.c, src/textformat.c, src/typval.c,
src/ui.c, src/userfunc.c, src/vim.h, src/vim9.h,
src/vim9compile.c, src/vim9execute.c, src/window.c,
src/testdir/test_cursorline.vim, src/os_unix.c, src/if_lua.c,
src/if_py_both.h, src/os_amiga.c, src/os_win32.c, src/os_mswin.c,
src/os_vms.c, src/os_vms_conf.h


*** ../vim-8.2.4927/src/bufwrite.c 2022-01-01 15:58:19.106486379 +0000
--- src/bufwrite.c 2022-05-09 19:06:06.120160447 +0100
***************
*** 30,36 ****
int bw_flags; // FIO_ flags
#ifdef FEAT_CRYPT
buf_T *bw_buffer; // buffer being written
! int bw_finish; // finish encrypting
#endif
char_u bw_rest[CONV_RESTLEN]; // not converted bytes
int bw_restlen; // nr of bytes in bw_rest[]
--- 30,36 ----
int bw_flags; // FIO_ flags
#ifdef FEAT_CRYPT
buf_T *bw_buffer; // buffer being written
! int bw_finish; // finish encrypting
#endif
char_u bw_rest[CONV_RESTLEN]; // not converted bytes
int bw_restlen; // nr of bytes in bw_rest[]
***************
*** 39,45 ****
size_t bw_conv_buflen; // size of bw_conv_buf
int bw_conv_error; // set for conversion error
linenr_T bw_conv_error_lnum; // first line with error or zero
! linenr_T bw_start_lnum; // line number at start of buffer
#ifdef USE_ICONV
iconv_t bw_iconv_fd; // descriptor for iconv() or -1
#endif
--- 39,45 ----
size_t bw_conv_buflen; // size of bw_conv_buf
int bw_conv_error; // set for conversion error
linenr_T bw_conv_error_lnum; // first line with error or zero
! linenr_T bw_start_lnum; // line number at start of buffer
#ifdef USE_ICONV
iconv_t bw_iconv_fd; // descriptor for iconv() or -1
#endif
*** ../vim-8.2.4927/src/channel.c 2022-05-07 16:38:20.489315665 +0100
--- src/channel.c 2022-05-09 19:06:14.904161352 +0100
***************
*** 1996,2002 ****
&& p[3] == ';')
{
// '\a' becomes a NL
! while (p < res + (len - 1) && *p != '\a')
++p;
// BEL is zero width characters, suppress display mistake
// ConPTY (after 10.0.18317) requires advance checking
--- 1996,2002 ----
&& p[3] == ';')
{
// '\a' becomes a NL
! while (p < res + (len - 1) && *p != '\a')
++p;
// BEL is zero width characters, suppress display mistake
// ConPTY (after 10.0.18317) requires advance checking
*** ../vim-8.2.4927/src/cindent.c 2022-05-07 20:01:10.050731702 +0100
--- src/cindent.c 2022-05-09 19:06:47.592163824 +0100
***************
*** 2181,2188 ****
check_linecomment(ml_get(curwin->w_cursor.lnum - 1));
if (linecomment_pos.col != MAXCOL)
{
! trypos = &linecomment_pos;
! trypos->lnum = curwin->w_cursor.lnum - 1;
}
}
if (trypos != NULL)
--- 2181,2188 ----
check_linecomment(ml_get(curwin->w_cursor.lnum - 1));
if (linecomment_pos.col != MAXCOL)
{
! trypos = &linecomment_pos;
! trypos->lnum = curwin->w_cursor.lnum - 1;
}
}
if (trypos != NULL)
*** ../vim-8.2.4927/src/crypt.c 2022-04-15 13:53:30.044708701 +0100
--- src/crypt.c 2022-05-09 19:07:03.368164549 +0100
***************
*** 452,459 ****
if (cryptmethods[method_nr].init_fn(
state, key, salt, salt_len, seed, seed_len) == FAIL)
{
! vim_free(state);
! return NULL;
}
return state;
}
--- 452,459 ----
if (cryptmethods[method_nr].init_fn(
state, key, salt, salt_len, seed, seed_len) == FAIL)
{
! vim_free(state);
! return NULL;
}
return state;
}
***************
*** 692,698 ****
cryptstate_T *state,
char_u *buf,
size_t len,
! int last)
{
cryptmethods[state->method_nr].encode_inplace_fn(state, buf, len,
buf, last);
--- 692,698 ----
cryptstate_T *state,
char_u *buf,
size_t len,
! int last)
{
cryptmethods[state->method_nr].encode_inplace_fn(state, buf, len,
buf, last);
*** ../vim-8.2.4927/src/debugger.c 2022-05-07 20:01:10.050731702 +0100
--- src/debugger.c 2022-05-09 19:07:10.780164810 +0100
***************
*** 22,28 ****

static char_u *debug_oldval = NULL; // old and newval for debug expressions
static char_u *debug_newval = NULL;
! static int debug_expr = 0; // use debug_expr

int
has_watchexpr(void)
--- 22,28 ----

static char_u *debug_oldval = NULL; // old and newval for debug expressions
static char_u *debug_newval = NULL;
! static int debug_expr = 0; // use debug_expr

int
has_watchexpr(void)
*** ../vim-8.2.4927/src/digraph.c 2022-05-07 20:01:10.050731702 +0100
--- src/digraph.c 2022-05-09 19:07:22.656165052 +0100
***************
*** 2337,2344 ****
flag_list_all = FALSE;
else
{
! int error = FALSE;
varnumber_T flag = tv_get_number_chk(&argvars[0], &error);
if (error)
return;
flag_list_all = flag ? TRUE : FALSE;
--- 2337,2345 ----
flag_list_all = FALSE;
else
{
! int error = FALSE;
varnumber_T flag = tv_get_number_chk(&argvars[0], &error);
+
if (error)
return;
flag_list_all = flag ? TRUE : FALSE;
*** ../vim-8.2.4927/src/edit.c 2022-05-07 20:01:10.054731696 +0100
--- src/edit.c 2022-05-09 19:07:58.472164886 +0100
***************
*** 3839,3846 ****
#ifdef FEAT_EVAL
set_vim_var_string(VV_INSERTMODE,
(char_u *)((State & REPLACE_FLAG) ? "i"
! : replaceState == MODE_VREPLACE ? "v"
! : "r"), 1);
#endif
ins_apply_autocmds(EVENT_INSERTCHANGE);
if (State & REPLACE_FLAG)
--- 3839,3845 ----
#ifdef FEAT_EVAL
set_vim_var_string(VV_INSERTMODE,
(char_u *)((State & REPLACE_FLAG) ? "i"
! : replaceState == MODE_VREPLACE ? "v" : "r"), 1);
#endif
ins_apply_autocmds(EVENT_INSERTCHANGE);
if (State & REPLACE_FLAG)
***************
*** 4895,4904 ****
// These five lines mean 'tabstop' != 'shiftwidth'
&& ((tabstop_count(curbuf->b_p_vts_array) > 1)
|| (tabstop_count(curbuf->b_p_vts_array) == 1
! && tabstop_first(curbuf->b_p_vts_array)
!= get_sw_value(curbuf))
! || (tabstop_count(curbuf->b_p_vts_array) == 0
! && curbuf->b_p_ts != get_sw_value(curbuf))))
&& tabstop_count(curbuf->b_p_vsts_array) == 0
#else
&& !(p_sta && ind && curbuf->b_p_ts != get_sw_value(curbuf))
--- 4894,4903 ----
// These five lines mean 'tabstop' != 'shiftwidth'
&& ((tabstop_count(curbuf->b_p_vts_array) > 1)
|| (tabstop_count(curbuf->b_p_vts_array) == 1
! && tabstop_first(curbuf->b_p_vts_array)
!= get_sw_value(curbuf))
! || (tabstop_count(curbuf->b_p_vts_array) == 0
! && curbuf->b_p_ts != get_sw_value(curbuf))))
&& tabstop_count(curbuf->b_p_vsts_array) == 0
#else
&& !(p_sta && ind && curbuf->b_p_ts != get_sw_value(curbuf))
***************
*** 4924,4930 ****
temp -= get_nolist_virtcol() % temp;
}
else if (tabstop_count(curbuf->b_p_vsts_array) > 0 || curbuf->b_p_sts != 0)
! // use 'softtabstop' when set
temp = tabstop_padding(get_nolist_virtcol(), get_sts_value(),
curbuf->b_p_vsts_array);
else // otherwise use 'tabstop'
--- 4923,4929 ----
temp -= get_nolist_virtcol() % temp;
}
else if (tabstop_count(curbuf->b_p_vsts_array) > 0 || curbuf->b_p_sts != 0)
! // use 'softtabstop' when set
temp = tabstop_padding(get_nolist_virtcol(), get_sts_value(),
curbuf->b_p_vsts_array);
else // otherwise use 'tabstop'
***************
*** 4963,4969 ****
*/
#ifdef FEAT_VARTABS
if (!curbuf->b_p_et && (tabstop_count(curbuf->b_p_vsts_array) > 0
! || get_sts_value() > 0
|| (p_sta && ind)))
#else
if (!curbuf->b_p_et && (get_sts_value() || (p_sta && ind)))
--- 4962,4968 ----
*/
#ifdef FEAT_VARTABS
if (!curbuf->b_p_et && (tabstop_count(curbuf->b_p_vsts_array) > 0
! || get_sts_value() > 0
|| (p_sta && ind)))
#else
if (!curbuf->b_p_et && (get_sts_value() || (p_sta && ind)))
*** ../vim-8.2.4927/src/evalwindow.c 2022-04-23 14:07:50.930670454 +0100
--- src/evalwindow.c 2022-05-09 19:08:08.512164593 +0100
***************
*** 155,160 ****
--- 155,162 ----

/*
* Find window specified by "vp" in tabpage "tp".
+ * Returns current window if "vp" is number zero.
+ * Returns NULL if not found.
*/
win_T *
find_win_by_nr(
***************
*** 997,1024 ****
|| !win_valid(wp) || !win_valid(targetwin)
|| win_valid_popup(wp) || win_valid_popup(targetwin))
{
! emsg(_(e_invalid_window_number));
rettv->vval.v_number = -1;
return;
}

if (argvars[2].v_type != VAR_UNKNOWN)
{
! dict_T *d;
! dictitem_T *di;

! if (argvars[2].v_type != VAR_DICT || argvars[2].vval.v_dict == NULL)
! {
! emsg(_(e_invalid_argument));
! return;
! }
!
! d = argvars[2].vval.v_dict;
! if (dict_get_bool(d, (char_u *)"vertical", FALSE))
! flags |= WSP_VERT;
! if ((di = dict_find(d, (char_u *)"rightbelow", -1)) != NULL)
! flags |= tv_get_bool(&di->di_tv) ? WSP_BELOW : WSP_ABOVE;
! size = (int)dict_get_number(d, (char_u *)"size");
}

win_move_into_split(wp, targetwin, size, flags);
--- 999,1026 ----
|| !win_valid(wp) || !win_valid(targetwin)
|| win_valid_popup(wp) || win_valid_popup(targetwin))
{
! emsg(_(e_invalid_window_number));
rettv->vval.v_number = -1;
return;
}

if (argvars[2].v_type != VAR_UNKNOWN)
{
! dict_T *d;
! dictitem_T *di;

! if (argvars[2].v_type != VAR_DICT || argvars[2].vval.v_dict == NULL)
! {
! emsg(_(e_invalid_argument));
! return;
! }
!
! d = argvars[2].vval.v_dict;
! if (dict_get_bool(d, (char_u *)"vertical", FALSE))
! flags |= WSP_VERT;
! if ((di = dict_find(d, (char_u *)"rightbelow", -1)) != NULL)
! flags |= tv_get_bool(&di->di_tv) ? WSP_BELOW : WSP_ABOVE;
! size = (int)dict_get_number(d, (char_u *)"size");
}

win_move_into_split(wp, targetwin, size, flags);
*** ../vim-8.2.4927/src/ex_cmds.c 2022-05-07 20:01:10.054731696 +0100
--- src/ex_cmds.c 2022-05-09 19:08:15.420164336 +0100
***************
*** 2511,2517 ****
#endif
int readfile_flags = 0;
int did_inc_redrawing_disabled = FALSE;
! long *so_ptr = curwin->w_p_so >= 0 ? &curwin->w_p_so : &p_so;

#ifdef FEAT_PROP_POPUP
if (ERROR_IF_TERM_POPUP_WINDOW)
--- 2511,2517 ----
#endif
int readfile_flags = 0;
int did_inc_redrawing_disabled = FALSE;
! long *so_ptr = curwin->w_p_so >= 0 ? &curwin->w_p_so : &p_so;

#ifdef FEAT_PROP_POPUP
if (ERROR_IF_TERM_POPUP_WINDOW)
*** ../vim-8.2.4927/src/ex_docmd.c 2022-05-07 20:01:10.054731696 +0100
--- src/ex_docmd.c 2022-05-09 19:08:19.576164159 +0100
***************
*** 2369,2375 ****
{
ea.line1 = ea.line2;
if (ea.line2 >= LONG_MAX - (n - 1))
! ea.line2 = LONG_MAX; // avoid overflow
else
ea.line2 += n - 1;
++ea.addr_count;
--- 2369,2375 ----
{
ea.line1 = ea.line2;
if (ea.line2 >= LONG_MAX - (n - 1))
! ea.line2 = LONG_MAX; // avoid overflow
else
ea.line2 += n - 1;
++ea.addr_count;
*** ../vim-8.2.4927/src/ex_getln.c 2022-05-07 20:01:10.054731696 +0100
--- src/ex_getln.c 2022-05-09 19:08:28.012163743 +0100
***************
*** 110,116 ****
{
// remove trailing \v and the like
while (len >= 2 && p[len - 2] == '\\'
! && vim_strchr((char_u *)"mMvVcCZ", p[len - 1]) != NULL)
len -= 2;

// true, if the pattern is empty, or the pattern ends with \| and magic is
--- 110,116 ----
{
// remove trailing \v and the like
while (len >= 2 && p[len - 2] == '\\'
! && vim_strchr((char_u *)"mMvVcCZ", p[len - 1]) != NULL)
len -= 2;

// true, if the pattern is empty, or the pattern ends with \| and magic is
*** ../vim-8.2.4927/src/fileio.c 2022-05-07 20:01:10.054731696 +0100
--- src/fileio.c 2022-05-09 19:08:34.776163354 +0100
***************
*** 216,222 ****
int using_b_ffname;
int using_b_fname;
static char *msg_is_a_directory = N_("is a directory");
! int eof;

au_did_filetype = FALSE; // reset before triggering any autocommands

--- 216,222 ----
int using_b_ffname;
int using_b_fname;
static char *msg_is_a_directory = N_("is a directory");
! int eof;

au_did_filetype = FALSE; // reset before triggering any autocommands

***************
*** 4784,4790 ****
int withattr UNUSED,
void *context,
int (*checkitem)(void *context, void *item),
! int sort)
{
int failed = FALSE;
char_u *p;
--- 4784,4790 ----
int withattr UNUSED,
void *context,
int (*checkitem)(void *context, void *item),
! int sort)
{
int failed = FALSE;
char_u *p;
*** ../vim-8.2.4927/src/filepath.c 2022-04-28 17:52:19.536130307 +0100
--- src/filepath.c 2022-05-09 19:08:42.648162844 +0100
***************
*** 1648,1654 ****
char_u *p;
garray_T ga;
int i;
! int sort = READDIR_SORT_BYTE;

if (rettv_list_alloc(rettv) == FAIL)
return;
--- 1648,1654 ----
char_u *p;
garray_T ga;
int i;
! int sort = READDIR_SORT_BYTE;

if (rettv_list_alloc(rettv) == FAIL)
return;
***************
*** 1701,1707 ****
char_u *path;
garray_T ga;
int i;
! int sort = READDIR_SORT_BYTE;

if (rettv_list_alloc(rettv) == FAIL)
return;
--- 1701,1707 ----
char_u *path;
garray_T ga;
int i;
! int sort = READDIR_SORT_BYTE;

if (rettv_list_alloc(rettv) == FAIL)
return;
*** ../vim-8.2.4927/src/gui.c 2022-05-07 20:01:10.058731693 +0100
--- src/gui.c 2022-05-09 19:08:56.828161784 +0100
***************
*** 5371,5377 ****
// escape slash and backslash
p = vim_strsave_escaped(find_text, (char_u *)"/\\");
if (p != NULL)
! ga_concat(&ga, p);
vim_free(p);
if (flags & FRD_WHOLE_WORD)
ga_concat(&ga, (char_u *)"\\>");
--- 5371,5377 ----
// escape slash and backslash
p = vim_strsave_escaped(find_text, (char_u *)"/\\");
if (p != NULL)
! ga_concat(&ga, p);
vim_free(p);
if (flags & FRD_WHOLE_WORD)
ga_concat(&ga, (char_u *)"\\>");
***************
*** 5445,5451 ****
// direction
p = vim_strsave_escaped(ga.ga_data, (char_u *)"?");
if (p != NULL)
! (void)do_search(NULL, '?', '?', p, 1L, searchflags, NULL);
vim_free(p);
}

--- 5445,5451 ----
// direction
p = vim_strsave_escaped(ga.ga_data, (char_u *)"?");
if (p != NULL)
! (void)do_search(NULL, '?', '?', p, 1L, searchflags, NULL);
vim_free(p);
}

*** ../vim-8.2.4927/src/highlight.c 2022-05-05 21:09:50.678323471 +0100
--- src/highlight.c 2022-05-09 19:09:04.836161109 +0100
***************
*** 2356,2362 ****
guicolor_T
gui_get_color_cmn(char_u *name)
{
! int i;
guicolor_T color;

struct rgbcolor_table_S {
--- 2356,2362 ----
guicolor_T
gui_get_color_cmn(char_u *name)
{
! int i;
guicolor_T color;

struct rgbcolor_table_S {
*** ../vim-8.2.4927/src/indent.c 2022-05-07 20:01:10.058731693 +0100
--- src/indent.c 2022-05-09 19:09:33.368158194 +0100
***************
*** 161,167 ****
int tabcount;
colnr_T tabcol = 0;
int t;
! int excess;

if (vts == NULL || vts[0] == 0)
return (col / ts) * ts;
--- 161,167 ----
int tabcount;
colnr_T tabcol = 0;
int t;
! int excess;

if (vts == NULL || vts[0] == 0)
return (col / ts) * ts;
***************
*** 1804,1810 ****
&& curbuf->b_p_ts == tabstop_first(new_vts_array))
; // not changed
else if (tabstop_count(curbuf->b_p_vts_array) > 0
! && tabstop_eq(curbuf->b_p_vts_array, new_vts_array))
; // not changed
else
redraw_curbuf_later(NOT_VALID);
--- 1804,1810 ----
&& curbuf->b_p_ts == tabstop_first(new_vts_array))
; // not changed
else if (tabstop_count(curbuf->b_p_vts_array) > 0
! && tabstop_eq(curbuf->b_p_vts_array, new_vts_array))
; // not changed
else
redraw_curbuf_later(NOT_VALID);
*** ../vim-8.2.4927/src/insexpand.c 2022-05-07 20:01:10.058731693 +0100
--- src/insexpand.c 2022-05-09 19:09:47.060156573 +0100
***************
*** 1966,1973 ****
p = vim_strsave(str);
if (p != NULL)
{
! vim_free(compl_first_match->cp_prev->cp_str);
! compl_first_match->cp_prev->cp_str = p;
}
}
}
--- 1966,1973 ----
p = vim_strsave(str);
if (p != NULL)
{
! vim_free(compl_first_match->cp_prev->cp_str);
! compl_first_match->cp_prev->cp_str = p;
}
}
}
***************
*** 3176,3182 ****
* st->first_match_pos - position of the first completion match
* st->last_match_pos - position of the last completion match
* st->set_match_pos - TRUE if the first match position should be saved to
! * avoid loops after the search wraps around.
* st->dict - name of the dictionary or thesaurus file to search
* st->dict_f - flag specifying whether "dict" is an exact file name or not
*
--- 3176,3182 ----
* st->first_match_pos - position of the first completion match
* st->last_match_pos - position of the last completion match
* st->set_match_pos - TRUE if the first match position should be saved to
! * avoid loops after the search wraps around.
* st->dict - name of the dictionary or thesaurus file to search
* st->dict_f - flag specifying whether "dict" is an exact file name or not
*
*** ../vim-8.2.4927/src/job.c 2022-05-07 16:38:20.489315665 +0100
--- src/job.c 2022-05-09 19:09:55.792155450 +0100
***************
*** 530,536 ****
}
// Allow empty string, "winpty", "conpty".
if (!(*p == NUL || STRCMP(p, "winpty") == 0
! || STRCMP(p, "conpty") == 0))
{
semsg(_(e_invalid_value_for_argument_str), "tty_type");
return FAIL;
--- 530,536 ----
}
// Allow empty string, "winpty", "conpty".
if (!(*p == NUL || STRCMP(p, "winpty") == 0
! || STRCMP(p, "conpty") == 0))
{
semsg(_(e_invalid_value_for_argument_str), "tty_type");
return FAIL;
*** ../vim-8.2.4927/src/keymap.h 2022-05-05 20:46:41.407274630 +0100
--- src/keymap.h 2022-05-09 19:16:21.644055288 +0100
***************
*** 276,282 ****
, KE_CANCEL = 102 // return from vgetc()
, KE_COMMAND = 103 // <Cmd> special key
, KE_SCRIPT_COMMAND = 104 // <ScriptCmd> special key
! , KE_S_BS = 105 // shift + <BS>
};

/*
--- 276,282 ----
, KE_CANCEL = 102 // return from vgetc()
, KE_COMMAND = 103 // <Cmd> special key
, KE_SCRIPT_COMMAND = 104 // <ScriptCmd> special key
! , KE_S_BS = 105 // shift + <BS>
};

/*
*** ../vim-8.2.4927/src/macros.h 2022-05-07 20:01:10.058731693 +0100
--- src/macros.h 2022-05-09 19:16:33.280051094 +0100
***************
*** 147,153 ****
// see mch_open() comment
# define mch_fopen(n, p) fopen(vms_fixfilename(n), (p))
# define mch_fstat(n, p) fstat((n), (p))
! # undef HAVE_LSTAT // VMS does not have lstat()
# define mch_stat(n, p) stat(vms_fixfilename(n), (p))
#else
# ifndef MSWIN
--- 147,153 ----
// see mch_open() comment
# define mch_fopen(n, p) fopen(vms_fixfilename(n), (p))
# define mch_fstat(n, p) fstat((n), (p))
! # undef HAVE_LSTAT // VMS does not have lstat()
# define mch_stat(n, p) stat(vms_fixfilename(n), (p))
#else
# ifndef MSWIN
***************
*** 208,214 ****
#define REPLACE_NORMAL(s) (((s) & REPLACE_FLAG) && !((s) & VREPLACE_FLAG))

#ifdef FEAT_ARABIC
! # define ARABIC_CHAR(ch) (((ch) & 0xFF00) == 0x0600)
# define UTF_COMPOSINGLIKE(p1, p2) utf_composinglike((p1), (p2))
#else
# define UTF_COMPOSINGLIKE(p1, p2) utf_iscomposing(utf_ptr2char(p2))
--- 208,214 ----
#define REPLACE_NORMAL(s) (((s) & REPLACE_FLAG) && !((s) & VREPLACE_FLAG))

#ifdef FEAT_ARABIC
! # define ARABIC_CHAR(ch) (((ch) & 0xFF00) == 0x0600)
# define UTF_COMPOSINGLIKE(p1, p2) utf_composinglike((p1), (p2))
#else
# define UTF_COMPOSINGLIKE(p1, p2) utf_iscomposing(utf_ptr2char(p2))
*** ../vim-8.2.4927/src/menu.c 2022-05-07 20:01:10.058731693 +0100
--- src/menu.c 2022-05-09 19:10:16.104152597 +0100
***************
*** 1638,1644 ****
modes = MENU_INSERT_MODE;
break;
case 't':
! if (*cmd == 'l') // tlmenu, tlunmenu, tlnoremenu
{
modes = MENU_TERMINAL_MODE;
++cmd;
--- 1638,1644 ----
modes = MENU_INSERT_MODE;
break;
case 't':
! if (*cmd == 'l') // tlmenu, tlunmenu, tlnoremenu
{
modes = MENU_TERMINAL_MODE;
++cmd;
*** ../vim-8.2.4927/src/misc1.c 2022-05-07 20:01:10.062731687 +0100
--- src/misc1.c 2022-05-09 19:10:21.836151718 +0100
***************
*** 575,581 ****
}

/*
! * Ask for a reply from the user, a 'y' or a 'n'.
* No other characters are accepted, the message is repeated until a valid
* reply is entered or CTRL-C is hit.
* If direct is TRUE, don't use vgetc() but ui_inchar(), don't get characters
--- 575,582 ----
}

/*
! * Ask for a reply from the user, a 'y' or a 'n', with prompt "str" (which
! * should have been translated already).
* No other characters are accepted, the message is repeated until a valid
* reply is entered or CTRL-C is hit.
* If direct is TRUE, don't use vgetc() but ui_inchar(), don't get characters
***************
*** 653,659 ****
{
buf[i++] = VIsual_mode;
if (restart_VIsual_select)
! buf[i++] = 's';
}
}
else if (State == MODE_HITRETURN || State == MODE_ASKMORE
--- 654,660 ----
{
buf[i++] = VIsual_mode;
if (restart_VIsual_select)
! buf[i++] = 's';
}
}
else if (State == MODE_HITRETURN || State == MODE_ASKMORE
*** ../vim-8.2.4927/src/misc2.c 2022-05-07 20:01:10.062731687 +0100
--- src/misc2.c 2022-05-09 19:10:26.924150931 +0100
***************
*** 647,653 ****
long lastcol;
colnr_T s, e;
int retval = FALSE;
! long siso = get_sidescrolloff_value();

changed_cline_bef_curs();
lastcol = curwin->w_leftcol + curwin->w_width - curwin_col_off() - 1;
--- 647,653 ----
long lastcol;
colnr_T s, e;
int retval = FALSE;
! long siso = get_sidescrolloff_value();

changed_cline_bef_curs();
lastcol = curwin->w_leftcol + curwin->w_width - curwin_col_off() - 1;
*** ../vim-8.2.4927/src/mouse.c 2022-05-07 20:01:10.062731687 +0100
--- src/mouse.c 2022-05-09 19:10:49.856147091 +0100
***************
*** 2284,2290 ****
// ^----- column
// ^-------- code
//
! // \033[<%d;%d;%dm : mouse release event
// ^-- row
// ^----- column
// ^-------- code
--- 2284,2290 ----
// ^----- column
// ^-------- code
//
! // \033[<%d;%d;%dm : mouse release event
// ^-- row
// ^----- column
// ^-------- code
***************
*** 2565,2573 ****
* Pe, the event code indicates what event caused this report
* The following event codes are defined:
* 0 - request, the terminal received an explicit request for a
! * locator report, but the locator is unavailable
* 1 - request, the terminal received an explicit request for a
! * locator report
* 2 - left button down
* 3 - left button up
* 4 - middle button down
--- 2565,2573 ----
* Pe, the event code indicates what event caused this report
* The following event codes are defined:
* 0 - request, the terminal received an explicit request for a
! * locator report, but the locator is unavailable
* 1 - request, the terminal received an explicit request for a
! * locator report
* 2 - left button down
* 3 - left button up
* 4 - middle button down
*** ../vim-8.2.4927/src/move.c 2022-05-08 19:39:27.658318960 +0100
--- src/move.c 2022-05-09 19:11:06.388144078 +0100
***************
*** 185,191 ****
#endif
int check_topline = FALSE;
int check_botline = FALSE;
! long *so_ptr = curwin->w_p_so >= 0 ? &curwin->w_p_so : &p_so;
int save_so = *so_ptr;

// If there is no valid screen and when the window height is zero just use
--- 185,191 ----
#endif
int check_topline = FALSE;
int check_botline = FALSE;
! long *so_ptr = curwin->w_p_so >= 0 ? &curwin->w_p_so : &p_so;
int save_so = *so_ptr;

// If there is no valid screen and when the window height is zero just use
***************
*** 435,441 ****
{
lineoff_T loff;
int n;
! long so = get_scrolloff_value();

if (curwin->w_cursor.lnum < curwin->w_topline + so
#ifdef FEAT_FOLDING
--- 435,441 ----
{
lineoff_T loff;
int n;
! long so = get_scrolloff_value();

if (curwin->w_cursor.lnum < curwin->w_topline + so
#ifdef FEAT_FOLDING
***************
*** 951,958 ****
colnr_T startcol;
colnr_T endcol;
colnr_T prev_skipcol;
! long so = get_scrolloff_value();
! long siso = get_sidescrolloff_value();

/*
* First make sure that w_topline is valid (after moving the cursor).
--- 951,958 ----
colnr_T startcol;
colnr_T endcol;
colnr_T prev_skipcol;
! long so = get_scrolloff_value();
! long siso = get_sidescrolloff_value();

/*
* First make sure that w_topline is valid (after moving the cursor).
***************
*** 1976,1982 ****
linenr_T old_valid = curwin->w_valid;
int old_empty_rows = curwin->w_empty_rows;
linenr_T cln; // Cursor Line Number
! long so = get_scrolloff_value();

cln = curwin->w_cursor.lnum;
if (set_topbot)
--- 1976,1982 ----
linenr_T old_valid = curwin->w_valid;
int old_empty_rows = curwin->w_empty_rows;
linenr_T cln; // Cursor Line Number
! long so = get_scrolloff_value();

cln = curwin->w_cursor.lnum;
if (set_topbot)
***************
*** 2270,2276 ****
int above_wanted, below_wanted;
linenr_T cln; // Cursor Line Number
int max_off;
! long so = get_scrolloff_value();

/*
* How many lines we would like to have above/below the cursor depends on
--- 2270,2276 ----
int above_wanted, below_wanted;
linenr_T cln; // Cursor Line Number
int max_off;
! long so = get_scrolloff_value();

/*
* How many lines we would like to have above/below the cursor depends on
***************
*** 2390,2396 ****
int retval = OK;
lineoff_T loff;
linenr_T old_topline = curwin->w_topline;
! long so = get_scrolloff_value();

if (curbuf->b_ml.ml_line_count == 1) // nothing to do
{
--- 2390,2396 ----
int retval = OK;
lineoff_T loff;
linenr_T old_topline = curwin->w_topline;
! long so = get_scrolloff_value();

if (curbuf->b_ml.ml_line_count == 1) // nothing to do
{
*** ../vim-8.2.4927/src/normal.c 2022-05-07 20:01:10.062731687 +0100
--- src/normal.c 2022-05-09 19:11:20.380141396 +0100
***************
*** 2644,2650 ****
long old_fdl = curwin->w_p_fdl;
int old_fen = curwin->w_p_fen;
#endif
! long siso = get_sidescrolloff_value();

if (VIM_ISDIGIT(nchar) && !nv_z_get_count(cap, &nchar))
return;
--- 2644,2650 ----
long old_fdl = curwin->w_p_fdl;
int old_fen = curwin->w_p_fen;
#endif
! long siso = get_sidescrolloff_value();

if (VIM_ISDIGIT(nchar) && !nv_z_get_count(cap, &nchar))
return;
***************
*** 6307,6313 ****
// the unnamed register is 0
reg = 0;

! VIsual_select_reg = valid_yank_reg(reg, TRUE) ? reg : 0;
return;
}

--- 6307,6313 ----
// the unnamed register is 0
reg = 0;

! VIsual_select_reg = valid_yank_reg(reg, TRUE) ? reg : 0;
return;
}

*** ../vim-8.2.4927/src/ops.c 2022-05-07 20:01:10.062731687 +0100
--- src/ops.c 2022-05-09 19:11:30.724139292 +0100
***************
*** 625,631 ****

if (VIsual_select && oap->is_VIsual)
// use register given with CTRL_R, defaults to zero
! oap->regname = VIsual_select_reg;

#ifdef FEAT_CLIPBOARD
adjust_clip_reg(&oap->regname);
--- 625,631 ----

if (VIsual_select && oap->is_VIsual)
// use register given with CTRL_R, defaults to zero
! oap->regname = VIsual_select_reg;

#ifdef FEAT_CLIPBOARD
adjust_clip_reg(&oap->regname);
***************
*** 1208,1216 ****
curwin->w_cursor.col -= (virtcols + 1);
for (; virtcols >= 0; virtcols--)
{
! if ((*mb_char2len)(c) > 1)
replace_character(c);
! else
PBYTE(curwin->w_cursor, c);
if (inc(&curwin->w_cursor) == -1)
break;
--- 1208,1216 ----
curwin->w_cursor.col -= (virtcols + 1);
for (; virtcols >= 0; virtcols--)
{
! if ((*mb_char2len)(c) > 1)
replace_character(c);
! else
PBYTE(curwin->w_cursor, c);
if (inc(&curwin->w_cursor) == -1)
break;
*** ../vim-8.2.4927/src/option.c 2022-05-09 13:33:36.054167847 +0100
--- src/option.c 2022-05-09 19:12:06.452131540 +0100
***************
*** 489,495 ****
# ifdef VIMDLL
(!gui.in_use && !gui.starting) &&
# endif
! GetACP() != GetConsoleCP())
{
char buf[50];

--- 489,495 ----
# ifdef VIMDLL
(!gui.in_use && !gui.starting) &&
# endif
! GetACP() != GetConsoleCP())
{
char buf[50];

***************
*** 1016,1022 ****
* Default values depend on shell (cmd.exe is default shell):
*
* p_shcf p_sxq
! * cmd.exe - "/c" "("
* powershell.exe - "-Command" "\""
* pwsh.exe - "-c" "\""
* "sh" like shells - "-c" "\""
--- 1016,1022 ----
* Default values depend on shell (cmd.exe is default shell):
*
* p_shcf p_sxq
! * cmd.exe - "/c" "("
* powershell.exe - "-Command" "\""
* pwsh.exe - "-c" "\""
* "sh" like shells - "-c" "\""
***************
*** 3342,3348 ****
#ifdef FEAT_VARTABS
// Use the first 'vartabstop' value, or 'tabstop' if vts isn't in use.
curbuf->b_p_sw = tabstop_count(curbuf->b_p_vts_array) > 0
! ? tabstop_first(curbuf->b_p_vts_array)
: curbuf->b_p_ts;
#else
curbuf->b_p_sw = curbuf->b_p_ts;
--- 3342,3348 ----
#ifdef FEAT_VARTABS
// Use the first 'vartabstop' value, or 'tabstop' if vts isn't in use.
curbuf->b_p_sw = tabstop_count(curbuf->b_p_vts_array) > 0
! ? tabstop_first(curbuf->b_p_vts_array)
: curbuf->b_p_ts;
#else
curbuf->b_p_sw = curbuf->b_p_ts;
***************
*** 5143,5154 ****
clear_string_option(&buf->b_p_tc);
buf->b_tc_flags = 0;
break;
! case PV_SISO:
! curwin->w_p_siso = -1;
! break;
! case PV_SO:
! curwin->w_p_so = -1;
! break;
#ifdef FEAT_FIND_ID
case PV_DEF:
clear_string_option(&buf->b_p_def);
--- 5143,5154 ----
clear_string_option(&buf->b_p_tc);
buf->b_tc_flags = 0;
break;
! case PV_SISO:
! curwin->w_p_siso = -1;
! break;
! case PV_SO:
! curwin->w_p_so = -1;
! break;
#ifdef FEAT_FIND_ID
case PV_DEF:
clear_string_option(&buf->b_p_def);
***************
*** 5255,5262 ****
case PV_AR: return (char_u *)&(curbuf->b_p_ar);
case PV_TAGS: return (char_u *)&(curbuf->b_p_tags);
case PV_TC: return (char_u *)&(curbuf->b_p_tc);
! case PV_SISO: return (char_u *)&(curwin->w_p_siso);
! case PV_SO: return (char_u *)&(curwin->w_p_so);
#ifdef FEAT_FIND_ID
case PV_DEF: return (char_u *)&(curbuf->b_p_def);
case PV_INC: return (char_u *)&(curbuf->b_p_inc);
--- 5255,5262 ----
case PV_AR: return (char_u *)&(curbuf->b_p_ar);
case PV_TAGS: return (char_u *)&(curbuf->b_p_tags);
case PV_TC: return (char_u *)&(curbuf->b_p_tc);
! case PV_SISO: return (char_u *)&(curwin->w_p_siso);
! case PV_SO: return (char_u *)&(curwin->w_p_so);
#ifdef FEAT_FIND_ID
case PV_DEF: return (char_u *)&(curbuf->b_p_def);
case PV_INC: return (char_u *)&(curbuf->b_p_inc);
***************
*** 6514,6520 ****
char_u *fuzzystr,
int *numMatches,
char_u ***matches,
! int can_fuzzy)
{
int num_normal = 0; // Nr of matching non-term-code settings
int num_term = 0; // Nr of matching terminal code settings
--- 6514,6520 ----
char_u *fuzzystr,
int *numMatches,
char_u ***matches,
! int can_fuzzy)
{
int num_normal = 0; // Nr of matching non-term-code settings
int num_term = 0; // Nr of matching terminal code settings
***************
*** 6579,6585 ****
}
else if (!fuzzy && options[opt_idx].shortname != NULL
&& vim_regexec(regmatch,
! (char_u *)options[opt_idx].shortname, (colnr_T)0))
{
// Compare against the abbreviated option name (for regular
// expression match). Fuzzy matching (previous if) already
--- 6579,6585 ----
}
else if (!fuzzy && options[opt_idx].shortname != NULL
&& vim_regexec(regmatch,
! (char_u *)options[opt_idx].shortname, (colnr_T)0))
{
// Compare against the abbreviated option name (for regular
// expression match). Fuzzy matching (previous if) already
*** ../vim-8.2.4927/src/option.h 2022-05-07 14:53:40.443628505 +0100
--- src/option.h 2022-05-09 19:16:40.184048602 +0100
***************
*** 267,274 ****
#define SHM_COMPLETIONMENU 'c' // completion menu messages
#define SHM_RECORDING 'q' // short recording message
#define SHM_FILEINFO 'F' // no file info messages
! #define SHM_SEARCHCOUNT 'S' // search stats: '[1/10]'
! #define SHM_POSIX "AS" // POSIX value
#define SHM_ALL "rmfixlnwaWtToOsAIcqFS" // all possible flags for 'shm'

// characters for p_go:
--- 267,274 ----
#define SHM_COMPLETIONMENU 'c' // completion menu messages
#define SHM_RECORDING 'q' // short recording message
#define SHM_FILEINFO 'F' // no file info messages
! #define SHM_SEARCHCOUNT 'S' // search stats: '[1/10]'
! #define SHM_POSIX "AS" // POSIX value
#define SHM_ALL "rmfixlnwaWtToOsAIcqFS" // all possible flags for 'shm'

// characters for p_go:
*** ../vim-8.2.4927/src/search.c 2022-05-07 20:01:10.062731687 +0100
--- src/search.c 2022-05-09 19:14:01.816101160 +0100
***************
*** 2810,2817 ****
#endif
colnr_T save_dollar_vcol;
char_u *p;
! long *so = curwin->w_p_so >= 0 ? &curwin->w_p_so : &p_so;
! long *siso = curwin->w_p_siso >= 0 ? &curwin->w_p_siso : &p_siso;

/*
* Only show match for chars in the 'matchpairs' option.
--- 2810,2817 ----
#endif
colnr_T save_dollar_vcol;
char_u *p;
! long *so = curwin->w_p_so >= 0 ? &curwin->w_p_so : &p_so;
! long *siso = curwin->w_p_siso >= 0 ? &curwin->w_p_siso : &p_siso;

/*
* Only show match for chars in the 'matchpairs' option.
***************
*** 4189,4202 ****
li = list_find(di->di_tv.vval.v_list, 1L);
if (li != NULL)
{
! pos.col = tv_get_number_chk(&li->li_tv, &error) - 1;
if (error)
return;
}
li = list_find(di->di_tv.vval.v_list, 2L);
if (li != NULL)
{
! pos.coladd = tv_get_number_chk(&li->li_tv, &error);
if (error)
return;
}
--- 4189,4202 ----
li = list_find(di->di_tv.vval.v_list, 1L);
if (li != NULL)
{
! pos.col = tv_get_number_chk(&li->li_tv, &error) - 1;
if (error)
return;
}
li = list_find(di->di_tv.vval.v_list, 2L);
if (li != NULL)
{
! pos.coladd = tv_get_number_chk(&li->li_tv, &error);
if (error)
return;
}
*** ../vim-8.2.4927/src/session.c 2022-05-01 00:42:16.046989890 +0100
--- src/session.c 2022-05-09 19:14:10.268098658 +0100
***************
*** 972,984 ****
// Restore 'shortmess'.
if (ssop_flags & SSOP_OPTIONS)
{
! if (fprintf(fd, "set shortmess=%s", p_shm) < 0 || put_eol(fd) == FAIL)
! goto fail;
}
else
{
! if (put_line(fd, "let &shortmess = s:shortmess_save") == FAIL)
! goto fail;
}

if (restore_height_width)
--- 972,984 ----
// Restore 'shortmess'.
if (ssop_flags & SSOP_OPTIONS)
{
! if (fprintf(fd, "set shortmess=%s", p_shm) < 0 || put_eol(fd) == FAIL)
! goto fail;
}
else
{
! if (put_line(fd, "let &shortmess = s:shortmess_save") == FAIL)
! goto fail;
}

if (restore_height_width)
*** ../vim-8.2.4927/src/spellsuggest.c 2022-03-16 13:33:22.078467971 +0000
--- src/spellsuggest.c 2022-04-27 14:16:57.393432295 +0100
***************
*** 3133,3143 ****
// TODO: also soundfold the next words, so that we can try joining
// and splitting
#ifdef SUGGEST_PROFILE
! prof_init();
#endif
suggest_trie_walk(su, lp, salword, TRUE);
#ifdef SUGGEST_PROFILE
! prof_report("soundalike");
#endif
}
}
--- 3133,3143 ----
// TODO: also soundfold the next words, so that we can try joining
// and splitting
#ifdef SUGGEST_PROFILE
! prof_init();
#endif
suggest_trie_walk(su, lp, salword, TRUE);
#ifdef SUGGEST_PROFILE
! prof_report("soundalike");
#endif
}
}
*** ../vim-8.2.4927/src/structs.h 2022-05-07 16:38:20.485315667 +0100
--- src/structs.h 2022-05-09 19:17:10.252037441 +0100
***************
*** 1650,1656 ****
# if defined(FEAT_LUA)
cfunc_T uf_cb; // callback function for cfunc
cfunc_free_T uf_cb_free; // callback function to free cfunc
! void *uf_cb_state; // state of uf_cb
# endif

garray_T uf_lines; // function lines
--- 1650,1656 ----
# if defined(FEAT_LUA)
cfunc_T uf_cb; // callback function for cfunc
cfunc_free_T uf_cb_free; // callback function to free cfunc
! void *uf_cb_state; // state of uf_cb
# endif

garray_T uf_lines; // function lines
***************
*** 2080,2094 ****
*/
typedef enum {
ETYPE_TOP, // toplevel
! ETYPE_SCRIPT, // sourcing script, use es_info.sctx
! ETYPE_UFUNC, // user function, use es_info.ufunc
! ETYPE_AUCMD, // autocomand, use es_info.aucmd
! ETYPE_MODELINE, // modeline, use es_info.sctx
! ETYPE_EXCEPT, // exception, use es_info.exception
! ETYPE_ARGS, // command line argument
! ETYPE_ENV, // environment variable
! ETYPE_INTERNAL, // internal operation
! ETYPE_SPELL, // loading spell file
} etype_T;

typedef struct {
--- 2080,2094 ----
*/
typedef enum {
ETYPE_TOP, // toplevel
! ETYPE_SCRIPT, // sourcing script, use es_info.sctx
! ETYPE_UFUNC, // user function, use es_info.ufunc
! ETYPE_AUCMD, // autocomand, use es_info.aucmd
! ETYPE_MODELINE, // modeline, use es_info.sctx
! ETYPE_EXCEPT, // exception, use es_info.exception
! ETYPE_ARGS, // command line argument
! ETYPE_ENV, // environment variable
! ETYPE_INTERNAL, // internal operation
! ETYPE_SPELL, // loading spell file
} etype_T;

typedef struct {
*** ../vim-8.2.4927/src/tag.c 2022-05-07 20:01:10.066731684 +0100
--- src/tag.c 2022-05-09 19:14:28.544093088 +0100
***************
*** 280,286 ****
int skip_msg = FALSE;
char_u *buf_ffname = curbuf->b_ffname; // name to use for
// priority computation
! int use_tfu = 1;

// remember the matches for the last used tag
static int num_matches = 0;
--- 280,286 ----
int skip_msg = FALSE;
char_u *buf_ffname = curbuf->b_ffname; // name to use for
// priority computation
! int use_tfu = 1;

// remember the matches for the last used tag
static int num_matches = 0;
***************
*** 1422,1429 ****
pos_T save_pos;
list_T *taglist;
listitem_T *item;
! int ntags = 0;
! int result = FAIL;
typval_T args[4];
typval_T rettv;
char_u flagString[4];
--- 1422,1429 ----
pos_T save_pos;
list_T *taglist;
listitem_T *item;
! int ntags = 0;
! int result = FAIL;
typval_T args[4];
typval_T rettv;
char_u flagString[4];
***************
*** 1820,1826 ****
static int
findtags_apply_tfu(findtags_state_T *st, char_u *pat, char_u *buf_ffname)
{
! int use_tfu = ((st->flags & TAG_NO_TAGFUNC) == 0);
int retval;

if (!use_tfu || tfu_in_use || *curbuf->b_p_tfu == NUL)
--- 1820,1826 ----
static int
findtags_apply_tfu(findtags_state_T *st, char_u *pat, char_u *buf_ffname)
{
! int use_tfu = ((st->flags & TAG_NO_TAGFUNC) == 0);
int retval;

if (!use_tfu || tfu_in_use || *curbuf->b_p_tfu == NUL)
*** ../vim-8.2.4927/src/term.c 2022-05-07 20:01:10.066731684 +0100
--- src/term.c 2022-05-09 19:14:46.176087582 +0100
***************
*** 688,694 ****
{K_K8, "\316\372"},
{K_K9, "\316\376"},
{K_BS, "\316x"},
! {K_S_BS, "\316y"},
# endif

# if defined(VMS) || defined(ALL_BUILTIN_TCAPS)
--- 688,694 ----
{K_K8, "\316\372"},
{K_K9, "\316\376"},
{K_BS, "\316x"},
! {K_S_BS, "\316y"},
# endif

# if defined(VMS) || defined(ALL_BUILTIN_TCAPS)
*** ../vim-8.2.4927/src/terminal.c 2022-05-07 20:01:10.066731684 +0100
--- src/terminal.c 2022-05-09 19:14:55.264084677 +0100
***************
*** 4442,4456 ****
// remove HOSTNAME to get PWD
while (*pos != '/' && offset < (int)frag->len)
{
! offset += 1;
! pos += 1;
}

if (offset >= (int)frag->len)
{
! semsg(_(e_failed_to_extract_pwd_from_str_check_your_shell_config),
frag->str);
! return;
}

new_dir = alloc(frag->len - offset + 1);
--- 4442,4456 ----
// remove HOSTNAME to get PWD
while (*pos != '/' && offset < (int)frag->len)
{
! offset += 1;
! pos += 1;
}

if (offset >= (int)frag->len)
{
! semsg(_(e_failed_to_extract_pwd_from_str_check_your_shell_config),
frag->str);
! return;
}

new_dir = alloc(frag->len - offset + 1);
*** ../vim-8.2.4927/src/textformat.c 2022-05-07 20:01:10.066731684 +0100
--- src/textformat.c 2022-05-09 19:15:00.920082850 +0100
***************
*** 176,182 ****
// Increment count of how many whitespace chars in this
// group; we only need to know if it's more than one.
if (wcc < 2)
! wcc++;
}
if (curwin->w_cursor.col == 0 && WHITECHAR(cc))
break; // only spaces in front of text
--- 176,182 ----
// Increment count of how many whitespace chars in this
// group; we only need to know if it's more than one.
if (wcc < 2)
! wcc++;
}
if (curwin->w_cursor.col == 0 && WHITECHAR(cc))
break; // only spaces in front of text
*** ../vim-8.2.4927/src/typval.c 2022-05-06 13:14:43.793076613 +0100
--- src/typval.c 2022-05-09 19:15:07.496080710 +0100
***************
*** 971,977 ****
case VAR_SPECIAL:
STRCPY(buf, get_var_special_name(varp->vval.v_number));
return buf;
! case VAR_BLOB:
emsg(_(e_using_blob_as_string));
break;
case VAR_JOB:
--- 971,977 ----
case VAR_SPECIAL:
STRCPY(buf, get_var_special_name(varp->vval.v_number));
return buf;
! case VAR_BLOB:
emsg(_(e_using_blob_as_string));
break;
case VAR_JOB:
*** ../vim-8.2.4927/src/ui.c 2022-02-23 12:23:04.501304722 +0000
--- src/ui.c 2022-05-09 19:15:29.392073445 +0100
***************
*** 199,208 ****
* while (not timed out)
* {
* if (any-timer-triggered)
! * invoke-timer-callback;
* wait-for-character();
* if (character available)
! * break;
* }
*
* wait-for-character() does:
--- 199,208 ----
* while (not timed out)
* {
* if (any-timer-triggered)
! * invoke-timer-callback;
* wait-for-character();
* if (character available)
! * break;
* }
*
* wait-for-character() does:
***************
*** 210,222 ****
* {
* Wait for event;
* if (something on channel)
! * read/write channel;
! * else if (resized)
! * handle_resize();
! * else if (system event)
! * deal-with-system-event;
! * else if (character available)
! * break;
* }
*
*/
--- 210,222 ----
* {
* Wait for event;
* if (something on channel)
! * read/write channel;
! * else if (resized)
! * handle_resize();
! * else if (system event)
! * deal-with-system-event;
! * else if (character available)
! * break;
* }
*
*/
*** ../vim-8.2.4927/src/userfunc.c 2022-05-06 15:47:01.618335092 +0100
--- src/userfunc.c 2022-05-09 19:15:37.460070712 +0100
***************
*** 2511,2517 ****
goto failed;
if (fill_partial_and_closure(pt, ufunc, ectx) == FAIL)
{
! vim_free(pt);
goto failed;
}
ufunc->uf_partial = pt;
--- 2511,2517 ----
goto failed;
if (fill_partial_and_closure(pt, ufunc, ectx) == FAIL)
{
! vim_free(pt);
goto failed;
}
ufunc->uf_partial = pt;
*** ../vim-8.2.4927/src/vim.h 2022-05-08 14:59:40.871968915 +0100
--- src/vim.h 2022-05-09 19:17:17.752034604 +0100
***************
*** 1375,1382 ****
// entering its window
EVENT_TERMRESPONSE, // after setting "v:termresponse"
EVENT_TEXTCHANGED, // text was modified not in Insert mode
! EVENT_TEXTCHANGEDI, // text was modified in Insert mode
! EVENT_TEXTCHANGEDP, // TextChangedI with popup menu visible
EVENT_TEXTYANKPOST, // after some text was yanked
EVENT_USER, // user defined autocommand
EVENT_VIMENTER, // after starting Vim
--- 1375,1382 ----
// entering its window
EVENT_TERMRESPONSE, // after setting "v:termresponse"
EVENT_TEXTCHANGED, // text was modified not in Insert mode
! EVENT_TEXTCHANGEDI, // text was modified in Insert mode
! EVENT_TEXTCHANGEDP, // TextChangedI with popup menu visible
EVENT_TEXTYANKPOST, // after some text was yanked
EVENT_USER, // user defined autocommand
EVENT_VIMENTER, // after starting Vim
*** ../vim-8.2.4927/src/vim9.h 2022-04-28 12:00:45.109439279 +0100
--- src/vim9.h 2022-05-09 19:17:23.616032376 +0100
***************
*** 500,506 ****

// Number of entries used by stack frame for a function call.
// - ec_dfunc_idx: function index
! // - ec_iidx: instruction index
// - ec_instr: instruction list pointer
// - ec_outer: stack used for closures
// - funclocal: function-local data
--- 500,506 ----

// Number of entries used by stack frame for a function call.
// - ec_dfunc_idx: function index
! // - ec_iidx: instruction index
// - ec_instr: instruction list pointer
// - ec_outer: stack used for closures
// - funclocal: function-local data
*** ../vim-8.2.4927/src/vim9compile.c 2022-05-08 16:36:55.208009371 +0100
--- src/vim9compile.c 2022-05-08 19:27:46.434446948 +0100
***************
*** 1041,1047 ****
// Skip the opening {.
block_start = skipwhite(p + 1);
block_end = block_start;
! if (*block_start != NUL &&skip_expr(&block_end, NULL) == FAIL)
return FAIL;
block_end = skipwhite(block_end);
// The block must be closed by a }.
--- 1041,1047 ----
// Skip the opening {.
block_start = skipwhite(p + 1);
block_end = block_start;
! if (*block_start != NUL && skip_expr(&block_end, NULL) == FAIL)
return FAIL;
block_end = skipwhite(block_end);
// The block must be closed by a }.
*** ../vim-8.2.4927/src/vim9execute.c 2022-05-05 13:52:59.416192105 +0100
--- src/vim9execute.c 2022-05-09 19:15:57.900063668 +0100
***************
*** 64,76 ****
// arg2 second argument from caller (if present)
// extra_arg1 any missing optional argument default value
// FP -> cur_func calling function
! // current previous instruction pointer
! // frame_ptr previous Frame Pointer
! // var1 space for local variable
! // var2 space for local variable
! // .... fixed space for max. number of local variables
! // temp temporary values
! // .... flexible space for temporary values (can grow big)

/*
* Execution context.
--- 64,76 ----
// arg2 second argument from caller (if present)
// extra_arg1 any missing optional argument default value
// FP -> cur_func calling function
! // current previous instruction pointer
! // frame_ptr previous Frame Pointer
! // var1 space for local variable
! // var2 space for local variable
! // .... fixed space for max. number of local variables
! // temp temporary values
! // .... flexible space for temporary values (can grow big)

/*
* Execution context.
***************
*** 6162,6168 ****
iptr->isn_arg.string);
break;
case ISN_PUT:
! if (iptr->isn_arg.put.put_lnum == LNUM_VARIABLE_RANGE_ABOVE)
smsg("%s%4d PUT %c above range",
pfx, current, iptr->isn_arg.put.put_regname);
else if (iptr->isn_arg.put.put_lnum == LNUM_VARIABLE_RANGE)
--- 6162,6168 ----
iptr->isn_arg.string);
break;
case ISN_PUT:
! if (iptr->isn_arg.put.put_lnum == LNUM_VARIABLE_RANGE_ABOVE)
smsg("%s%4d PUT %c above range",
pfx, current, iptr->isn_arg.put.put_regname);
else if (iptr->isn_arg.put.put_lnum == LNUM_VARIABLE_RANGE)
*** ../vim-8.2.4927/src/window.c 2022-05-07 20:01:10.066731684 +0100
--- src/window.c 2022-05-09 19:16:05.692060947 +0100
***************
*** 6371,6378 ****
// - window height is sufficient to display the whole buffer and first line
// is visible.
if (height > 0
! && (!wp->w_p_scb || wp == curwin)
! && (height < wp->w_buffer->b_ml.ml_line_count || wp->w_topline > 1))
{
/*
* Find a value for w_topline that shows the cursor at the same
--- 6371,6378 ----
// - window height is sufficient to display the whole buffer and first line
// is visible.
if (height > 0
! && (!wp->w_p_scb || wp == curwin)
! && (height < wp->w_buffer->b_ml.ml_line_count || wp->w_topline > 1))
{
/*
* Find a value for w_topline that shows the cursor at the same
*** ../vim-8.2.4927/src/testdir/test_cursorline.vim 2022-04-20 22:07:25.110829353 +0100
--- src/testdir/test_cursorline.vim 2022-04-20 22:30:41.049241187 +0100
***************
*** 298,304 ****

let lines =<< trim END
call setline(1, 'aa bb cc dd ee ff gg hh ii jj kk ll mm' ..
! \ ' nn oo pp qq rr ss tt uu vv ww xx yy zz')
set nowrap
" The following makes the cursor apparent on the screen dump
set sidescroll=1 cursorcolumn
--- 298,304 ----

let lines =<< trim END
call setline(1, 'aa bb cc dd ee ff gg hh ii jj kk ll mm' ..
! \ ' nn oo pp qq rr ss tt uu vv ww xx yy zz')
set nowrap
" The following makes the cursor apparent on the screen dump
set sidescroll=1 cursorcolumn
*** ../vim-8.2.4927/src/os_unix.c 2022-05-07 20:01:10.062731687 +0100
--- src/os_unix.c 2022-05-09 19:12:57.548119043 +0100
***************
*** 1778,1787 ****
{
if (eap->arg != NULL && STRLEN(eap->arg) > 0)
{
! if (xterm_display_allocated)
! vim_free(xterm_display);
! xterm_display = (char *)vim_strsave(eap->arg);
! xterm_display_allocated = TRUE;
}
smsg(_("restoring display %s"), xterm_display == NULL
? (char *)mch_getenv((char_u *)"DISPLAY") : xterm_display);
--- 1778,1787 ----
{
if (eap->arg != NULL && STRLEN(eap->arg) > 0)
{
! if (xterm_display_allocated)
! vim_free(xterm_display);
! xterm_display = (char *)vim_strsave(eap->arg);
! xterm_display_allocated = TRUE;
}
smsg(_("restoring display %s"), xterm_display == NULL
? (char *)mch_getenv((char_u *)"DISPLAY") : xterm_display);
***************
*** 7210,7216 ****
{
if (p_verbose > 0)
smsg_attr(HL_ATTR(HLF_W),
! _("Could not load gpm library: %s"), dlerror());
return FAIL;
}

--- 7210,7216 ----
{
if (p_verbose > 0)
smsg_attr(HL_ATTR(HLF_W),
! _("Could not load gpm library: %s"), dlerror());
return FAIL;
}

*** ../vim-8.2.4927/src/if_lua.c 2022-01-01 14:19:44.044353848 +0000
--- src/if_lua.c 2022-05-09 19:09:20.124159642 +0100
***************
*** 949,977 ****
li = list_find(l, n);
if (li == NULL)
{
! if (!lua_isnil(L, 3))
! {
! typval_T v;
! luaV_checktypval(L, 3, &v, "inserting list item");
! if (list_insert_tv(l, &v, li) == FAIL)
! luaL_error(L, "failed to add item to list");
! clear_tv(&v);
! }
}
else
{
! if (lua_isnil(L, 3)) // remove?
! {
vimlist_remove(l, li, li);
listitem_free(l, li);
! }
! else
! {
typval_T v;
luaV_checktypval(L, 3, &v, "setting list item");
clear_tv(&li->li_tv);
li->li_tv = v;
! }
}
return 0;
}
--- 949,977 ----
li = list_find(l, n);
if (li == NULL)
{
! if (!lua_isnil(L, 3))
! {
! typval_T v;
! luaV_checktypval(L, 3, &v, "inserting list item");
! if (list_insert_tv(l, &v, li) == FAIL)
! luaL_error(L, "failed to add item to list");
! clear_tv(&v);
! }
}
else
{
! if (lua_isnil(L, 3)) // remove?
! {
vimlist_remove(l, li, li);
listitem_free(l, li);
! }
! else
! {
typval_T v;
luaV_checktypval(L, 3, &v, "setting list item");
clear_tv(&li->li_tv);
li->li_tv = v;
! }
}
return 0;
}
*** ../vim-8.2.4927/src/version.c 2022-05-09 14:12:10.716386671 +0100
--- src/version.c 2022-05-09 20:08:52.470644222 +0100
***************
*** 748,749 ****
--- 748,751 ----
{ /* Add new patch number below this line */
+ /**/
+ 4928,
/**/

--
hundred-and-one symptoms of being an internet addict:
161. You get up before the sun rises to check your e-mail, and you
find yourself in the very same chair long after the sun has set.

/// Bram Moolenaar -- Br...@Moolenaar.net -- http://www.Moolenaar.net \\\
/// \\\
\\\ sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ ///
\\\ help me help AIDS victims -- http://ICCF-Holland.org ///
Reply all
Reply to author
Forward
0 new messages