mirror of
https://github.com/vim/vim.git
synced 2025-07-26 11:04:33 -04:00
patch 8.2.2245: Vim9: return value of winrestcmd() cannot be executed
Problem: Vim9: return value of winrestcmd() cannot be executed. Solution: Put colons before each range. (closes #7571)
This commit is contained in:
parent
89015a6759
commit
285b15fce1
@ -1010,9 +1010,9 @@ f_winrestcmd(typval_T *argvars UNUSED, typval_T *rettv)
|
|||||||
ga_init2(&ga, (int)sizeof(char), 70);
|
ga_init2(&ga, (int)sizeof(char), 70);
|
||||||
FOR_ALL_WINDOWS(wp)
|
FOR_ALL_WINDOWS(wp)
|
||||||
{
|
{
|
||||||
sprintf((char *)buf, "%dresize %d|", winnr, wp->w_height);
|
sprintf((char *)buf, ":%dresize %d|", winnr, wp->w_height);
|
||||||
ga_concat(&ga, buf);
|
ga_concat(&ga, buf);
|
||||||
sprintf((char *)buf, "vert %dresize %d|", winnr, wp->w_width);
|
sprintf((char *)buf, "vert :%dresize %d|", winnr, wp->w_width);
|
||||||
ga_concat(&ga, buf);
|
ga_concat(&ga, buf);
|
||||||
++winnr;
|
++winnr;
|
||||||
}
|
}
|
||||||
|
@ -716,5 +716,15 @@ def Test_win_splitmove()
|
|||||||
close
|
close
|
||||||
enddef
|
enddef
|
||||||
|
|
||||||
|
def Test_winrestcmd()
|
||||||
|
split
|
||||||
|
var cmd = winrestcmd()
|
||||||
|
wincmd _
|
||||||
|
exe cmd
|
||||||
|
assert_equal(cmd, winrestcmd())
|
||||||
|
close
|
||||||
|
enddef
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
" vim: ts=8 sw=2 sts=2 expandtab tw=80 fdm=marker
|
" vim: ts=8 sw=2 sts=2 expandtab tw=80 fdm=marker
|
||||||
|
@ -750,6 +750,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 */
|
||||||
|
/**/
|
||||||
|
2245,
|
||||||
/**/
|
/**/
|
||||||
2244,
|
2244,
|
||||||
/**/
|
/**/
|
||||||
|
Loading…
x
Reference in New Issue
Block a user