Bram Moolenaar
d0edaf9dc2
patch 8.2.2897: Vim9: can use reserved words at the script level
...
Problem: Vim9: can use reserved words at the script level.
Solution: Check variable names for reserved words. (closes #8253 )
2021-05-28 21:06:08 +02:00
mityu
4ac198c61c
patch 8.2.2895: Vim9: random characters appear in some error messages
...
Problem: Vim9: random characters appear in some error messages.
Solution: Pass the correct pointer. (closes #8277 )
2021-05-28 17:52:40 +02:00
Bram Moolenaar
b777da9be8
patch 8.2.2878: Vim9: for loop list unpack only allows for one "_"
...
Problem: Vim9: for loop list unpack only allows for one "_".
Solution: Drop the value when the variable is "_". (closes #8232 )
2021-05-22 21:40:39 +02:00
Dominique Pelle
4781d6fd86
patch 8.2.2871: unnessary VIM_ISDIGIT() calls, badly indented code
...
Problem: Unnessary VIM_ISDIGIT() calls, badly indented code.
Solution: Call skipdigits() on the next character. Improve indenting.
(Dominique Pellé, closes #8227 )
2021-05-18 21:46:31 +02:00
Bram Moolenaar
3b1373b193
patch 8.2.2861: Vim9: "legacy return" is not recognized as a return statement
...
Problem: Vim9: "legacy return" is not recognized as a return statement.
Solution: Specifically check for a return command. (closes #8213 )
2021-05-17 00:01:42 +02:00
Bram Moolenaar
ff65288aa8
patch 8.2.2857: Vim9: exception in ISN_INSTR caught at wrong level
...
Problem: Vim9: exception in ISN_INSTR caught at wrong level.
Solution: Set the starting trylevel in exec_instructions(). (closes #8214 )
2021-05-16 15:24:49 +02:00
Bram Moolenaar
68db996b62
patch 8.2.2846: Vim9: "echo Func()" does not give an error for using void
...
Problem: Vim9: "echo Func()" does not give an error for a function without
a return value.
Solution: Give an error. Be more specific about why a value is invalid.
2021-05-09 23:19:22 +02:00
Bram Moolenaar
f06ab6ba38
patch 8.2.2843: Vim9: skip argument to searchpairpos() is not compiled
...
Problem: Vim9: skip argument to searchpairpos() is not compiled.
Solution: Handle like searchpair(). Also for search() and searchpos().
2021-05-07 19:44:21 +02:00
Bram Moolenaar
f18332fb9e
patch 8.2.2842: Vim9: skip argument to searchpair() is not compiled
...
Problem: Vim9: skip argument to searchpair() is not compiled.
Solution: Add VAR_INSTR.
2021-05-07 17:55:55 +02:00
Bram Moolenaar
261417b872
patch 8.2.2840: Vim9: member operation not fully tested
...
Problem: Vim9: member operation not fully tested.
Solution: Add a few tests.
2021-05-06 21:04:55 +02:00
Bram Moolenaar
b7c978154e
patch 8.2.2836: build failure without the +quickfix feature
...
Problem: Build failure without the +quickfix feature. (John Marriott)
Solution: Add #ifdef.
2021-05-05 22:51:39 +02:00
Bram Moolenaar
dc3e2e65c9
patch 8.2.2835: Vim9: leaking memory in :cexpr
...
Problem: Vim9: leaking memory in :cexpr.
Solution: Also free the command line copy.
2021-05-05 22:40:56 +02:00
Bram Moolenaar
5f7d4c049e
patch 8.2.2834: Vim9: :cexpr does not work with local variables
...
Problem: Vim9: :cexpr does not work with local variables.
Solution: Compile :cexpr.
2021-05-05 21:31:39 +02:00
Bram Moolenaar
dc4c2309f2
patch 8.2.2809: Vim9: :def function compilation fails when using :legacy
...
Problem: Vim9: :def function compilation fails when using :legacy.
Solution: Reset CMOD_LEGACY when compiling a function. (closes #8137 )
2021-04-25 13:54:42 +02:00
Bram Moolenaar
bdc0f1c698
patch 8.2.2806: Vim9: using "++nr" as a command might not work
...
Problem: Vim9: using "++nr" as a command might not work.
Solution: Do not recognize "++" and "--" in a following line as addition or
subtraction.
2021-04-24 19:08:24 +02:00
Bram Moolenaar
96cf4ba8fb
patch 8.2.2805: Vim9: cannot use legacy syntax in Vim9 script
...
Problem: Vim9: cannot use legacy syntax in Vim9 script.
Solution: Add the :legacy command.
2021-04-24 14:15:41 +02:00
Bram Moolenaar
a369c3d9c1
patch 8.2.2798: Vim9: redir to variable with append does not accept an index
...
Problem: Vim9: redir to variable with append does not accept an index.
Solution: Make the appending work.
2021-04-21 16:00:10 +02:00
Bram Moolenaar
753bcf8c7d
patch 8.2.2796: Vim9: redir to variable does not accept an index
...
Problem: Vim9: redir to variable does not accept an index.
Solution: Make the index work.
2021-04-21 14:24:24 +02:00
Bram Moolenaar
169502fb0b
patch 8.2.2795: Coverity warns for not using return value
...
Problem: Coverity warns for not using return value.
Solution: Check the return value of compiling the substitute expression.
2021-04-21 12:19:35 +02:00
Bram Moolenaar
5c787fb792
patch 8.2.2791: Vim9: memory leak when using \=expr in :substitute
...
Problem: Vim9: memory leak when using \=expr in :substitute.
Solution: Do not allocate a new instruction list.
2021-04-20 21:49:35 +02:00
Bram Moolenaar
8238f08838
patch 8.2.2789: Vim9: using \=expr in :substitute does not handle jumps
...
Problem: Vim9: using \=expr in :substitute does not handle jumps.
Solution: Start with instruction count zero. (closes #8128 )
2021-04-20 21:10:48 +02:00
Bram Moolenaar
4f2df37a0d
patch 8.2.2786: Vim9: memory leak when using :s with expression
...
Problem: Vim9: memory leak when using :s with expression.
Solution: Clean up the instruction list.
2021-04-19 21:06:31 +02:00
Bram Moolenaar
2d1c57ed3d
patch 8.2.2785: Vim9: cannot redirect to local variable
...
Problem: Vim9: cannot redirect to local variable.
Solution: Compile :redir when redirecting to a variable.
2021-04-19 20:50:03 +02:00
Bram Moolenaar
4c13721482
patch 8.2.2784: Vim9: cannot use \=expr in :substitute
...
Problem: Vim9: cannot use \=expr in :substitute.
Solution: Compile the expression into instructions and execute them when
invoked.
2021-04-19 16:48:48 +02:00
Bram Moolenaar
d551d6c268
patch 8.2.2780: Vim9: for loop over blob doesn't work
...
Problem: Vim9: for loop over blob doesn't work.
Solution: Make it work.
2021-04-18 13:15:58 +02:00
Bram Moolenaar
51e933261b
patch 8.2.2777: Vim9: blob operations not tested in all ways
...
Problem: Vim9: blob operations not tested in all ways.
Solution: Run tests with CheckLegacyAndVim9Success(). Make blob assign with
index work.
2021-04-17 20:44:56 +02:00
Bram Moolenaar
c70fe460b0
patch 8.2.2775: Vim9: wrong line number used for some commands
...
Problem: Vim9: wrong line number used for some commands.
Solution: For :exe, :echo and the like use the line number of the start of
the command. When calling a function set the line number in the
script context.
2021-04-17 17:59:19 +02:00
Bram Moolenaar
fe090eb58f
patch 8.2.2770: Vim9: type of loop variable is not used
...
Problem: Vim9: type of loop variable is not used.
Solution: Parse and check the variable type. (closes #8107 )
2021-04-15 21:48:32 +02:00
Bram Moolenaar
f387f5dfbc
patch 8.2.2768: Vim9: memory leak with blob range error
...
Problem: Vim9: memory leak with blob range error.
Solution: Jump to end instead of returning.
2021-04-15 13:42:21 +02:00
Bram Moolenaar
b141926890
patch 8.2.2766: test failure
...
Problem: Test failure.
Solution: Add change to Vim9 compilation error message.
2021-04-14 20:54:07 +02:00
Bram Moolenaar
f62d73933a
patch 8.2.2762: Vim9: function line truncated when compiling
...
Problem: Vim9: function line truncated when compiling.
Solution: Copy the line before processing it. (closes #8101 )
2021-04-14 12:40:00 +02:00
Bram Moolenaar
f6a8d420a8
patch 8.2.2760: Vim9: no error for changing a for loop variable
...
Problem: Vim9: no error for changing a for loop variable.
Solution: Make the loop variable read-only. (issue #8102 )
2021-04-13 21:48:03 +02:00
Bram Moolenaar
68452177ca
patch 8.2.2757: Vim9: blob tests for legacy and Vim9 script are separate
...
Problem: Vim9: blob tests for legacy and Vim9 script are separate.
Solution: Add CheckLegacyAndVim9Success(). Make blob index assign work.
2021-04-12 21:21:02 +02:00
Bram Moolenaar
cfc3023cb6
patch 8.2.2756: Vim9: blob index and slice not implemented yet
...
Problem: Vim9: blob index and slice not implemented yet.
Solution: Implement blob index and slice.
2021-04-11 20:26:34 +02:00
Bram Moolenaar
af8ea0d066
patch 8.2.2755: Vim9: no error for using a number in a condition
...
Problem: Vim9: no error for using a number in a condition.
Solution: Also use ISN_COND2BOOL if the type is t_number_bool.
(closes #7644 )
2021-04-11 18:24:46 +02:00
Bram Moolenaar
f93bbd0262
patch 8.2.2753: Vim9: cannot ignore an item in assignment unpack
...
Problem: Vim9: cannot ignore an item in assignment unpack.
Solution: Allow using an underscore.
2021-04-10 22:35:43 +02:00
Bram Moolenaar
da479c7597
patch 8.2.2750: Vim9: error for using underscore in nested function
...
Problem: Vim9: error for using underscore in nested function.
Solution: Do not consider "_" already defined. (closes #8096 )
2021-04-10 21:01:38 +02:00
Bram Moolenaar
962c43bf0d
patch 8.2.2744: Vim9: no way to explicitly ignore an argument
...
Problem: Vim9: no way to explicitly ignore an argument.
Solution: Use the underscore as the name for an ignored argument.
2021-04-10 17:18:09 +02:00
Bram Moolenaar
599410cb3c
patch 8.2.2743: Vim9: function state stuck when compiling with ":silent!"
...
Problem: Vim9: function state stuck when compiling with ":silent!".
Solution: Check for uf_def_status to be UF_COMPILING.
2021-04-10 14:03:43 +02:00
Bram Moolenaar
701cc6ca9e
patch 8.2.2742: Vim9: when compiling a function fails it is cleared
...
Problem: Vim9: when compiling a function fails it is cleared.
Solution: Keep the function lines, prevent execution with a different
status. (closes #8093 )
2021-04-10 13:33:48 +02:00
Bram Moolenaar
1088b69451
patch 8.2.2741: Vim9: Partial call does not check right arguments
...
Problem: Vim9: Partial call does not check right arguments.
Solution: Adjust the offset for whether the partial is before or after the
arguments. (closes #8091 )
2021-04-09 22:12:44 +02:00
Bram Moolenaar
2a38908b05
patch 8.2.2740: Vim9: lambda with varargs doesn't work
...
Problem: Vim9: lambda with varargs doesn't work.
Solution: Make "...name" work. Require type to be a list.
2021-04-09 20:24:31 +02:00
Bram Moolenaar
fa5963880d
patch 8.2.2735: Vim9: function reference found with prefix, not without
...
Problem: Vim9: function reference found with prefix, not without.
Solution: Also find function reference without prefix.
2021-04-07 21:58:16 +02:00
Bram Moolenaar
15e5e53ef2
patch 8.2.2734: Vim9: cannot use legacy script-local var from :def function
...
Problem: Vim9: cannot use legacy script-local var from :def function.
Solution: Do not insist on using "s:" prefix. (closes #8076 )
2021-04-07 21:21:13 +02:00
Bram Moolenaar
c9605f0595
patch 8.2.2730: Coverity complains about not restoring character
...
Problem: Coverity complains about not restoring character.
Solution: Also restore the character in case of an error.
2021-04-06 21:29:32 +02:00
Bram Moolenaar
643ce6c0c6
patch 8.2.2729: Vim9: wrong error message for referring to legacy script var
...
Problem: Vim9: wrong error message for referring to legacy script variable.
Solution: Do allow referring to a variable in legacy script without "s:" if
it exists at compile time. (closes #8076 )
2021-04-06 21:17:27 +02:00
Bram Moolenaar
b9c0cd897a
patch 8.2.2722: Vim9: crash when using LHS with double index
...
Problem: Vim9: crash when using LHS with double index.
Solution: Handle lhs_dest which is "dest_expr". (closes #8068 )
Fix confusing error message for missing dict item.
2021-04-05 20:51:00 +02:00
Bram Moolenaar
2927c07b0e
patch 8.2.2721: Vim9: cannot have a linebreak inside a lambda
...
Problem: Vim9: cannot have a linebreak inside a lambda.
Solution: Compile the expression before the arguments.
2021-04-05 19:41:21 +02:00
Bram Moolenaar
e42939af87
patch 8.2.2719: Vim9: appending to dict item doesn't work in a :def function
...
Problem: Vim9: appending to dict item doesn't work in a :def function.
Solution: Implement assignment with operator on indexed item.
2021-04-05 17:11:17 +02:00
Bram Moolenaar
90193e6140
patch 8.2.2710: Vim9: not all tests cover script and :def function
...
Problem: Vim9: not all tests cover script and :def function.
Solution: Run tests in both if possible. Fix differences.
2021-04-04 20:49:50 +02:00