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
b7c21afef1
patch 8.2.2781: add() silently skips when adding to null list or blob
...
Problem: Add() silently skips when adding to null list or blob.
Solution: Give an error in Vim9 script. Allocate blob when it is NULL like
with list and dict.
2021-04-18 14:12:31 +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
bd6406f15d
patch 8.2.2767: compiler warning for unused argument
...
Problem: Compiler warning for unused argument.
Solution: Remove the argument.
2021-04-14 21:30:06 +02:00
Bram Moolenaar
0e3ff19196
patch 8.2.2765: Vim9: not all blob operations work
...
Problem: Vim9: not all blob operations work.
Solution: Run more tests also with Vim9 script and :def functions. Fix what
doesn't work.
2021-04-14 20:35:23 +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
c429769776
patch 8.2.2748: Vim9: memory leak when calling :def function fails
...
Problem: Vim9: memory leak when calling :def function fails.
Solution: Jump to failed_early instead of returning.
2021-04-10 20:46:48 +02:00
Bram Moolenaar
bb8a7ce0a1
patch 8.2.2747: Vim9: not always an error for too many function arguments
...
Problem: Vim9: not always an error for too many function arguments.
Solution: Check for getting too many arguments.
2021-04-10 20:10:26 +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
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
175a41c13f
patch 8.2.2736: Vim9: for loop over string is a bit slow
...
Problem: Vim9: for loop over string is a bit slow.
Solution: Avoid using strlen().
2021-04-08 18:05:03 +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
Bram Moolenaar
6e50ec2f0a
patch 8.2.2703: Vim9: memory leak when failing on locked variable
...
Problem: Vim9: memory leak when failing on locked variable.
Solution: Free the memory.
2021-04-03 19:32:44 +02:00
Bram Moolenaar
dcf29ac87f
patch 8.2.2693: Vim9: locked script variable can be changed
...
Problem: Vim9: locked script variable can be changed.
Solution: Check legacy script variable for being locked. (issue #8031 )
2021-04-02 14:44:02 +02:00
Bram Moolenaar
f5906aa780
patch 8.2.2692: Vim9: locked script variable can be changed
...
Problem: Vim9: locked script variable can be changed.
Solution: Check for locked value. (closes #8031 )
2021-04-02 14:35:15 +02:00
Bram Moolenaar
d877a5700f
patch 8.2.2687: Vim9: cannot use "const" for global variable in :def function
...
Problem: Vim9: cannot use "const" for global variable in :def function.
Solution: Do allow using :const for a global variable. (closes #8030 )
2021-04-01 19:42:48 +02:00
Bram Moolenaar
38a3bfa9a2
patch 8.2.2677: Vim9: cannot use only some of the default arguments
...
Problem: Vim9: cannot use only some of the default arguments.
Solution: Use v:none to use default argument value. Remove
uf_def_arg_idx[], use JUMP_IF_ARG_SET. (closes #6504 )
2021-03-29 22:14:55 +02:00
Bram Moolenaar
74e54fcb44
patch 8.2.2658: :for cannot loop over a string
...
Problem: :for cannot loop over a string.
Solution: Accept a string argument and iterate over its characters.
2021-03-26 20:41:29 +01:00
Bram Moolenaar
ff87140046
patch 8.2.2654: Vim9: getting a character from a string can be slow
...
Problem: Vim9: getting a character from a string can be slow.
Solution: Avoid a function call to get the character byte size. (#8000 )
2021-03-26 13:34:05 +01:00
Bram Moolenaar
a91a71322d
patch 8.2.2651: Vim9: restoring command modifiers happens after jump
...
Problem: Vim9: restoring command modifiers happens after jump.
Solution: Move the restore instruction to before the jump. (closes #8006 )
Also handle for and while.
2021-03-25 21:12:15 +01:00
Bram Moolenaar
2fecb53115
patch 8.2.2650: Vim9: command modifiers not handled in nested function
...
Problem: Vim9: command modifiers not handled in nested function.
Solution: Keep function-local info in a structure and save it on the stack.
2021-03-24 22:00:56 +01:00
Bram Moolenaar
c970e4225b
patch 8.2.2614: Vim9: function is deleted while executing
...
Problem: Vim9: function is deleted while executing.
Solution: increment the call count, when more than zero do not delete the
function but mark it as dead. (closes #7977 )
2021-03-17 15:03:04 +01:00
Bram Moolenaar
0289a093a4
patch 8.2.2605: Vim9: string index and slice does not include composing chars
...
Problem: Vim9: string index and slice does not include composing chars.
Solution: Include composing characters. (issue #6563 )
2021-03-14 18:40:19 +01:00
Bram Moolenaar
2e34c34be1
patch 8.2.2602: Vim9: continue doesn't work if :while is very first command
...
Problem: Vim9: continue doesn't work if :while is very first command.
(Yegappan Lakshmanan)
Solution: Add one to the continue instruction index.
2021-03-14 12:13:33 +01:00
Bram Moolenaar
cb4e80fab9
patch 8.2.2597: Vim9: "import * as" does not work at script level
...
Problem: Vim9: "import * as" does not work at script level.
Solution: Implement using an imported namespace.
2021-03-13 20:57:19 +01:00
Bram Moolenaar
e3ffcd9902
patch 8.2.2580: Vim9: checking vararg type may be wrong
...
Problem: Vim9: checking vararg type is wrong when function is auto-loaded.
Solution: Use the member type. (closes #7933 )
2021-03-08 21:47:13 +01:00
Bram Moolenaar
04947cc6ed
patch 8.2.2574: Vim9: crash when calling partial with wrong function
...
Problem: Vim9: crash when calling partial with wrong function.
Solution: Check argument types of called function. (closes #7912 )
2021-03-06 19:26:46 +01:00
Bram Moolenaar
1bd3cb2019
patch 8.2.2549: crash after using "g:" in a for loop
...
Problem: Crash after using "g:" in a for loop.
Solution: Increment the reference count. (closes #7892 )
2021-02-24 12:27:31 +01:00
Bram Moolenaar
9cb577a682
patch 8.2.2543: Vim9: a return inside try/catch does not restore properly
...
Problem: Vim9: a return inside try/catch does not restore exception state
properly.
Solution: When there is no ":finally" jump to ":endtry". (closes #7882 )
2021-02-22 22:45:10 +01:00
Bram Moolenaar
7e82c5f338
patch 8.2.2539: Vim9: return from finally block causes a hang
...
Problem: Vim9: return from finally block causes a hang.
Solution: Store both the finally and endtry indexes. (closes #7885 )
2021-02-21 21:32:45 +01:00
Bram Moolenaar
5b5ae29bd3
patch 8.2.2533: Vim9: cannot use a range with :unlet
...
Problem: Vim9: cannot use a range with :unlet.
Solution: Implement ISN_UNLETRANGE.
2021-02-20 17:04:02 +01:00
Bram Moolenaar
12d265315f
patch 8.2.2530: Vim9: not enough testing for profiling
...
Problem: Vim9: not enough testing for profiling.
Solution: Add a test with nested functions and a lambda. Fix profiling
for calling a compiled function.
2021-02-19 19:13:21 +01:00
Bram Moolenaar
8d4be89011
patch 8.2.2509: tests fail on s390 build
...
Problem: Tests fail on s390 build.
Solution: Initialize trycmd_T.
2021-02-13 18:33:02 +01:00
Bram Moolenaar
c150c09ec4
patch 8.2.2506: Vim9: :continue does not work correctly in a :try block
...
Problem: Vim9: :continue does not work correctly in a :try block
Solution: Add the TRYCLEANUP instruction. (closes #7827 )
2021-02-13 15:02:46 +01:00
Bram Moolenaar
d9d7789b6f
patch 8.2.2503: Vim9: a caught error may leave something on the stack
...
Problem: Vim9: a caught error may leave something on the stack.
Solution: Drop items from the stack if needed. (closes #7826 )
2021-02-12 21:32:47 +01:00
Bram Moolenaar
f785aa1354
patch 8.2.2501: not always clear where an error is reported
...
Problem: Not always clear where an error is reported.
Solution: Add the where_T structure and pass it around. (closes #7796 )
2021-02-11 21:19:34 +01:00
Bram Moolenaar
fef8064b54
patch 8.2.2461: Coverity warns for unchecked return value
...
Problem: Coverity warns for unchecked return value.
Solution: Add "(void)" to avoid the warning.
2021-02-03 20:01:19 +01:00
Bram Moolenaar
3445320839
patch 8.2.2435: setline() gives an error for some types
...
Problem: setline() gives an error for some types.
Solution: Allow any type, convert each item to a string.
2021-01-31 13:08:38 +01:00
Bram Moolenaar
e5ea346a07
patch 8.2.2409: Vim9: profiling only works for one function
...
Problem: Vim9: profiling only works for one function.
Solution: Select the right instructions when calling and returning.
(closes #7743 )
2021-01-25 21:01:48 +01:00
Bram Moolenaar
107e9cecf7
patch 8.2.2404: Vim9: profiling try/catch not correct
...
Problem: Vim9: profiling try/catch not correct.
Solution: Add profile instructions. Fix that "entry" did not rethrow an
excpetion.
2021-01-24 20:52:00 +01:00
Bram Moolenaar
f002a41d12
patch 8.2.2401: build fails without +profiling feature
...
Problem: Build fails without +profiling feature.
Solution: Add #ifdefs.
2021-01-24 13:34:18 +01:00
Bram Moolenaar
b204990346
patch 8.2.2400: Vim9: compiled functions are not profiled
...
Problem: Vim9: compiled functions are not profiled.
Solution: Add initial changes to profile compiled functions. Fix that a
script-local function was hard to debug.
2021-01-24 12:53:53 +01:00
Bram Moolenaar
0d3de8cb59
patch 8.2.2391: memory leak when creating a global function with closure
...
Problem: Memory leak when creating a global function with closure.
Solution: Create a separate partial for every instantiated function.
2021-01-22 20:46:27 +01:00
Bram Moolenaar
b3005ce191
patch 8.2.2390: Vim9: using positive offset is unexpected
...
Problem: Vim9: using positive offset is unexpected.
Solution: Use int8_T instead of char. (James McCoy)
2021-01-22 17:51:06 +01:00
Bram Moolenaar
9b6344613e
patch 8.2.2389: test failure on a few systems
...
Problem: Test failure on a few systems.
Solution: Avoid that "char" value is negative.
2021-01-21 22:53:38 +01:00
Bram Moolenaar
e32e516dfa
patch 8.2.2387: runtime type check does not mention argument index
...
Problem: Runtime type check does not mention argument index.
Solution: Add ct_arg_idx. (closes #7720 )
2021-01-21 20:21:29 +01:00
Bram Moolenaar
f904133e1a
patch 8.2.2386: Vim9: crash when using ":silent! put"
...
Problem: Vim9: crash when using ":silent! put".
Solution: When ignoring an error for ":silent!" rewind the stack and skip
ahead to restoring the cmdmod. (closes #7717 )
2021-01-21 19:41:16 +01:00