mirror of
https://github.com/neovim/neovim.git
synced 2026-07-16 06:10:39 +00:00
Merge pull request #39211 from janlazo/vim-8.2.2245
vim-patch:8.2.{2245,3024}
This commit is contained in:
@@ -869,10 +869,10 @@ void f_winrestcmd(typval_T *argvars, typval_T *rettv, EvalFuncData fptr)
|
||||
continue;
|
||||
}
|
||||
size_t buflen = vim_snprintf_safelen(buf, sizeof(buf),
|
||||
"%dresize %d|", winnr, wp->w_height);
|
||||
":%dresize %d|", winnr, wp->w_height);
|
||||
ga_concat_len(&ga, buf, buflen);
|
||||
buflen = vim_snprintf_safelen(buf, sizeof(buf),
|
||||
"vert %dresize %d|", winnr, wp->w_width);
|
||||
"vert :%dresize %d|", winnr, wp->w_width);
|
||||
ga_concat_len(&ga, buf, buflen);
|
||||
winnr++;
|
||||
}
|
||||
|
||||
@@ -45,7 +45,7 @@ func Test_execute_string()
|
||||
if has('float')
|
||||
call assert_fails('call execute(3.4)', 'E492:')
|
||||
call assert_equal("\nx", execute("echo \"x\"", 3.4))
|
||||
call CheckDefExecAndScriptFailure(['execute("echo \"x\"", 3.4)'], 'E806:')
|
||||
call CheckDefExecAndScriptFailure2(['execute("echo \"x\"", 3.4)'], 'E1013: Argument 2: type mismatch, expected string but got float', 'E806:')
|
||||
endif
|
||||
endfunc
|
||||
|
||||
|
||||
@@ -58,6 +58,11 @@ func CheckDefExecAndScriptFailure(lines, error, lnum = -3)
|
||||
return
|
||||
endfunc
|
||||
|
||||
" As CheckDefExecAndScriptFailure() but with two different expected errors.
|
||||
func CheckDefExecAndScriptFailure2(lines, errorDef, errorScript, lnum = -3)
|
||||
return
|
||||
endfunc
|
||||
|
||||
" Check that "lines" inside a legacy function has no error.
|
||||
func CheckLegacySuccess(lines)
|
||||
let cwd = getcwd()
|
||||
|
||||
Reference in New Issue
Block a user