1
0
forked from aniani/vim

patch 8.2.1301: Vim9: varargs argument type not parsed properly

Problem:    Vim9: varargs argument type not parsed properly.
Solution:   Skip over the "...". (issue #6507)
This commit is contained in:
Bram Moolenaar
2020-07-26 18:16:58 +02:00
parent 4fc224ca1c
commit ace6132aa8
3 changed files with 17 additions and 0 deletions

View File

@@ -1956,6 +1956,8 @@ skip_type(char_u *start, int optional)
{
char_u *sp = p;
if (STRNCMP(p, "...", 3) == 0)
p += 3;
p = skip_type(p, TRUE);
if (p == sp)
return p; // syntax error