Bram Moolenaar
7226e5b19b
patch 8.2.1356: Vim9: cannot get the percent register
...
Problem: Vim9: cannot get the percent register.
Solution: Check for readable registers instead of writable. (closes #6566 )
2020-08-02 17:33:26 +02:00
Bram Moolenaar
c2ee44cc38
patch 8.2.1355: Vim9: no error using :let for options and registers
...
Problem: Vim9: no error using :let for options and registers.
Solution: Give an error. (closes #6568 )
2020-08-02 16:59:00 +02:00
Bram Moolenaar
ad486a0f0d
patch 8.2.1352: Vim9: no error for shadowing a script-local function
...
Problem: Vim9: no error for shadowing a script-local function by a nested
function.
Solution: Check for script-local function. (closes #6586 )
2020-08-01 23:22:18 +02:00
Bram Moolenaar
bcbf41395f
patch 8.2.1351: Vim9: no proper error if using namespace for nested function
...
Problem: Vim9: no proper error if using namespace for nested function.
Solution: Specifically check for a namespace. (closes #6582 )
2020-08-01 22:35:13 +02:00
Bram Moolenaar
eef2102e20
patch 8.2.1349: Vim9: can define a function with the name of an import
...
Problem: Vim9: can define a function with the name of an import.
Solution: Disallow using an existing name. (closes #6585 )
2020-08-01 22:16:43 +02:00
Bram Moolenaar
f5a48010ef
patch 8.2.1342: Vim9: accidentally using "t" gives a confusing error
...
Problem: Vim9: accidentally using "x" gives a confusing error.
Solution: Disallow using ":t" in Vim9 script. (issue #6399 )
2020-08-01 17:00:03 +02:00
Bram Moolenaar
2caa1594e7
patch 8.2.1339: Vim9: assigning to global dict variable doesn't work
...
Problem: Vim9: assigning to global dict variable doesn't work.
Solution: Guess variable type based in index type. (issue #6591 )
2020-08-01 15:53:19 +02:00
Bram Moolenaar
8e4c8c853e
patch 8.2.1338: Vim9: assigning to script-local variable doesn't check type
...
Problem: Vim9: assigning to script-local variable doesn't check type.
Solution: Use the type. (issue #6591 )
2020-08-01 15:38:38 +02:00
Bram Moolenaar
ce6583568f
patch 8.2.1332: Vim9: memory leak when using nested global function
...
Problem: Vim9: memory leak when using nested global function.
Solution: Delete the function when deleting the instruction. Disable test
that still causes a leak.
2020-07-31 23:47:12 +02:00
Bram Moolenaar
badd8486f7
patch 8.2.1331: Vim9: :echo with two lists doesn't work
...
Problem: Vim9: :echo with two lists doesn't work.
Solution: Do not skip white space before []. (closes #6552 )
2020-07-31 22:38:17 +02:00
Bram Moolenaar
38ddf333f6
patch 8.2.1329: Vim9: cannot define global function inside :def function
...
Problem: Vim9: cannot define global function inside :def function.
Solution: Assign to global variable instead of local. (closes #6584 )
2020-07-31 22:05:04 +02:00
Bram Moolenaar
696ba23149
patch 8.2.1323: Vim9: invalid operators only rejected in :def function
...
Problem: Vim9: invalid operators only rejected in :def function.
Solution: Also reject them at script level. (closes #6564 )
2020-07-29 21:20:41 +02:00
Bram Moolenaar
33afa2447b
patch 8.2.1320: Vim9: cannot declare some single letter variables
...
Problem: Vim9: cannot declare some single letter variables.
Solution: Do not recognize a colon for a namespace for single letter
variables. (closes #6547 )
2020-07-29 19:18:00 +02:00
Bram Moolenaar
ae616494d7
patch 8.2.1308: Vim9: accidentally using "x" causes Vim to exit
...
Problem: Vim9: accidentally using "x" causes Vim to exit.
Solution: Disallow using ":x" or "xit" in Vim9 script. (closes #6399 )
2020-07-28 20:07:27 +02:00
Bram Moolenaar
b13ab99908
patch 8.2.1306: checking for first character of dict key is inconsistent
...
Problem: Checking for first character of dict key is inconsistent.
Solution: Add eval_isdictc(). (closes #6546 )
2020-07-27 21:43:28 +02:00
Bram Moolenaar
01865ade85
patch 8.2.1302: Vim9: varargs arg after optional arg does not work
...
Problem: Vim9: varargs arg after optional arg does not work
Solution: Check for the "..." first. (issue #6507 )
2020-07-26 18:33:09 +02:00
Bram Moolenaar
ace6132aa8
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 )
2020-07-26 18:16:58 +02:00
Bram Moolenaar
4fc224ca1c
patch 8.2.1300: Vim9: optional argument type not parsed properly
...
Problem: Vim9: optional argument type not parsed properly.
Solution: Skip over the "?". (issue #6507 )
2020-07-26 17:56:25 +02:00
Bram Moolenaar
2d6b20d6a9
patch 8.2.1293: Vim9: error when using vim9script in TextYankPost
...
Problem: Vim9: error when using vim9script in TextYankPost.
Solution: Use EX_LOCKOK instead of the EX_CMDWIN flag for command that can
be used when text is locked. (closes #6529 )
2020-07-25 19:30:59 +02:00
Bram Moolenaar
40f4f7a48c
patch 8.2.1287: Vim9: crash when using an imported function
...
Problem: Vim9: crash when using an imported function.
Solution: Add the function type to the imported entry. (closes #6522 )
2020-07-23 22:41:43 +02:00
Bram Moolenaar
b8070e3173
patch 8.2.1285: Vim9: argument types are not checked on assignment
...
Problem: Vim9: argument types are not checked on assignment.
Solution: Check function argument types. (issue #6507 )
2020-07-23 20:56:04 +02:00
Bram Moolenaar
bfba8651a5
patch 8.2.1284: Vim9: skipping over type includes following white space
...
Problem: Vim9: skipping over type includes following white space, leading
to an error for missing white space.
Solution: Do not skip over white space after the type.
2020-07-23 20:09:10 +02:00
Bram Moolenaar
637cd7d1c9
patch 8.2.1283: Vim9: error for misplaced -> lacks argument
...
Problem: Vim9: error for misplaced -> lacks argument.
Solution: Use the pointer before it was advanced.
2020-07-23 19:06:23 +02:00
Bram Moolenaar
6c4bfe4b31
patch 8.2.1282: Vim9: crash when using CheckScriptFailure()
...
Problem: Vim9: crash when using CheckScriptFailure() in
Test_vim9script_call_fail_decl().
Solution: Do not decrement the def_functions len unless the function was
newly added.
2020-07-23 18:26:30 +02:00
Bram Moolenaar
dd1a9af00f
patch 8.2.1278: Vim9: line break after "->" only allowed in :def function
...
Problem: Vim9: line break after "->" only allowed in :def function.
Solution: Only allow line break after "->". (closes #6492 )
2020-07-23 15:38:03 +02:00
Bram Moolenaar
4cdb13ce81
patch 8.2.1272: Vim9: type not checked if declaration also assigns value
...
Problem: Vim9: type not checked if declaration also assigns value.
Solution: Check the type. (issue #6507 )
2020-07-22 21:45:14 +02:00
Bram Moolenaar
0f60e80f9b
patch 8.2.1271: Vim9: Error for Funcref function argument type
...
Problem: Vim9: Error for Funcref function argument type.
Solution: Find the actual function type if possible. (issue #6507 )
2020-07-22 20:16:11 +02:00
Bram Moolenaar
2f1980f7b7
patch 8.2.1270: Vim9: not skipping over function type declaration
...
Problem: Vim9: not skipping over function type declaration with only a
return type.
Solution: Skip over the return type. (issue #6507 )
2020-07-22 19:30:06 +02:00
Bram Moolenaar
c7db57788b
patch 8.2.1261: Vim9: common type of function not tested
...
Problem: Vim9: common type of function not tested.
Solution: Add a test. Fix uncovered problems.
2020-07-21 20:55:50 +02:00
Bram Moolenaar
7892b953e0
patch 8.2.1256: Vim9: type wrong after getting dict item in lambda
...
Problem: Vim9: type wrong after getting dict item in lambda.
Solution: Set the type to "any" after enforcing dict type. (closes #6491 )
2020-07-20 22:09:34 +02:00
Bram Moolenaar
2f8ce0ae8a
patch 8.2.1250: Vim9: cannot use the g:, b:, t: and w: namespaces
...
Problem: Vim9: cannot use the g:, b:, t: and w: namespaces.
Solution: Add instructions to push a dict for the namespaces. (closes #6480 )
2020-07-19 19:47:35 +02:00
Bram Moolenaar
bf9d8c3765
patch 8.2.1247: Vim9: cannot index a character in a string
...
Problem: Vim9: cannot index a character in a string.
Solution: Add ISN_STRINDEX instruction. (closes #6478 )
2020-07-19 17:55:44 +02:00
Bram Moolenaar
b209750b5e
patch 8.2.1246: Vim9: comment after assignment doesn't work
...
Problem: Vim9: comment after assignment doesn't work.
Solution: Skip over white space. (closes #6481 )
2020-07-19 17:17:02 +02:00
Bram Moolenaar
6802cce407
patch 8.2.1244: Vim9: in lambda index assumes a list
...
Problem: Vim9: in lambda index assumes a list.
Solution: Use the value type to decide about list or dict. (closes #6479 )
2020-07-19 15:49:49 +02:00
Bram Moolenaar
75783bd84e
patch 8.2.1243: Vim9: cannot have a comment line halfway a list
...
Problem: Vim9: cannot have a comment or empty line halfway a list at script
level.
Solution: Skip more than one line if needed.
2020-07-19 14:41:58 +02:00
Bram Moolenaar
65b9545f44
patch 8.2.1242: Vim9: no error if calling a function with wrong type
...
Problem: Vim9: no error if calling a function with wrong argument type.
Solution: Check types of arguments. (closes #6469 )
2020-07-19 14:03:09 +02:00
Bram Moolenaar
e859312e74
patch 8.2.1236: Vim9: a few errors not caught by try/catch
...
Problem: Vim9: a few errors not caught by try/catch.
Solution: Do not bail out if an error is inside try/catch. Fix that a not
matching catch doesn't jump to :endtry.
2020-07-18 15:17:02 +02:00
Bram Moolenaar
f5be8cdb77
patch 8.2.1227: Vim9: allowing both quoted and # comments is confusing
...
Problem: Vim9: allowing both quoted and # comments is confusing.
Solution: Only support # comments in Vim9 script.
2020-07-17 20:36:00 +02:00
Bram Moolenaar
e30f64b4b5
patch 8.2.1223: Vim9: invalid type error for function default value
...
Problem: Vim9: invalid type error for function default value.
Solution: Use right argument index. (closes #6458 )
2020-07-15 19:48:20 +02:00
Bram Moolenaar
3d48e25dcb
patch 8.2.1218: Vim9: cannot use 'text'->func()
...
Problem: Vim9: cannot use 'text'->func().
Solution: Recognize string at start of command.
2020-07-15 14:15:52 +02:00
Bram Moolenaar
f1a2368d81
patch 8.2.1201: Vim9: crash when passing number as dict key
...
Problem: Vim9: crash when passing number as dict key.
Solution: Check key type to be string. (closes #6449 )
2020-07-13 18:55:48 +02:00
Bram Moolenaar
985116ae0b
patch 8.2.1191: Vim9: crash when function calls itself
...
Problem: Vim9: crash when function calls itself.
Solution: Add status UF_COMPILING. (closes #6441 )
2020-07-12 17:31:09 +02:00
Bram Moolenaar
9b7bf9e98f
patch 8.2.1183: assert_fails() checks the last error message
...
Problem: assert_fails() checks the last error message.
Solution: Check the first error, it is more relevant. Fix all the tests
that rely on the old behavior.
2020-07-11 22:14:59 +02:00
Bram Moolenaar
b074e8b8d4
patch 8.2.1178: Vim9: filter function recognized as command modifier
...
Problem: Vim9: filter function recognized as command modifier, leading to a
crash.
Solution: Clear cmdmod after freeing items. Do not recognize a command
modifier followed by non-white space. (closes #6434 )
2020-07-11 13:40:45 +02:00
Bram Moolenaar
543e6f3467
patch 8.2.1176: Vim9: not enough type checking in Vim9 script
...
Problem: Vim9: not enough type checking in Vim9 script.
Solution: Use same type checking as in a :def function.
2020-07-10 22:45:38 +02:00
Bram Moolenaar
a7eedf317a
patch 8.2.1175: Vim9: cannot split a line before ".member"
...
Problem: Vim9: Cannot split a line before ".member".
Solution: Check for ".member" after line break.
2020-07-10 21:50:41 +02:00
Bram Moolenaar
389df259c4
patch 8.2.1167: Vim9: builtin function method call only supports first arg
...
Problem: Vim9: builtin function method call only supports first argument.
Solution: Shift arguments when needed. (closes #6305 , closes #6419 )
2020-07-09 21:20:47 +02:00
Bram Moolenaar
8e2730a315
patch 8.2.1161: Vim9: using freed memory
...
Problem: Vim9: using freed memory.
Solution: Put pointer back in evalarg instead of freeing it.
2020-07-08 22:01:49 +02:00
Bram Moolenaar
6110e79a58
patch 8.2.1160: Vim9: memory leak in allocated types
...
Problem: Vim9: memory leak in allocated types.
Solution: Free the type pointers.
2020-07-08 19:35:21 +02:00
Bram Moolenaar
6b7a0a8c20
patch 8.2.1159: Vim9: no error for missing space after a comma
...
Problem: Vim9: no error for missing space after a comma.
Solution: Check for white space.
2020-07-08 18:38:08 +02:00