mirror of
https://github.com/neovim/neovim.git
synced 2025-10-02 07:58:35 +00:00
@@ -69,6 +69,7 @@ static char *e_nowhitespace
|
|||||||
static char *e_invalwindow = N_("E957: Invalid window number");
|
static char *e_invalwindow = N_("E957: Invalid window number");
|
||||||
static char *e_lock_unlock = N_("E940: Cannot lock or unlock variable %s");
|
static char *e_lock_unlock = N_("E940: Cannot lock or unlock variable %s");
|
||||||
static char *e_write2 = N_("E80: Error while writing: %s");
|
static char *e_write2 = N_("E80: Error while writing: %s");
|
||||||
|
static char *e_string_list_or_blob_required = N_("E1098: String, List or Blob required");
|
||||||
|
|
||||||
// TODO(ZyX-I): move to eval/executor
|
// TODO(ZyX-I): move to eval/executor
|
||||||
static char *e_letwrong = N_("E734: Wrong variable type for %s=");
|
static char *e_letwrong = N_("E734: Wrong variable type for %s=");
|
||||||
@@ -2651,7 +2652,7 @@ void *eval_for_line(const char_u *arg, bool *errp, char_u **nextcmdp, int skip)
|
|||||||
fi->fi_string = vim_strsave((char_u *)"");
|
fi->fi_string = vim_strsave((char_u *)"");
|
||||||
}
|
}
|
||||||
} else {
|
} else {
|
||||||
emsg(_(e_listblobreq));
|
emsg(_(e_string_list_or_blob_required));
|
||||||
tv_clear(&tv);
|
tv_clear(&tv);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@@ -65,11 +65,9 @@ func Test_E963()
|
|||||||
endfunc
|
endfunc
|
||||||
|
|
||||||
func Test_for_invalid()
|
func Test_for_invalid()
|
||||||
" Vim gives incorrect emsg here until v8.2.3284, but the exact emsg from that
|
call assert_fails("for x in 99", 'E1098:')
|
||||||
" patch cannot be used until v8.2.2658 is ported (for loop over Strings)
|
call assert_fails("for x in function('winnr')", 'E1098:')
|
||||||
call assert_fails("for x in 99", 'E897:')
|
call assert_fails("for x in {'a': 9}", 'E1098:')
|
||||||
call assert_fails("for x in function('winnr')", 'E897:')
|
|
||||||
call assert_fails("for x in {'a': 9}", 'E897:')
|
|
||||||
|
|
||||||
if 0
|
if 0
|
||||||
/1/5/2/s/\n
|
/1/5/2/s/\n
|
||||||
|
Reference in New Issue
Block a user