Bram Moolenaar
e29a27f6f8
patch 8.2.3190: error messages are spread out
...
Problem: Error messages are spread out.
Solution: Move error messages to errors.h and give them a clear name.
2021-07-20 21:07:36 +02:00
Bram Moolenaar
c323527d67
patch 8.2.3137: Vim9: no error when a line only has a variable name
...
Problem: Vim9: no error when a line only has a variable name.
Solution: Give an error when an expression is evaluated without an effect.
(closes #8538 )
2021-07-10 19:42:03 +02:00
Bram Moolenaar
d4ab807d62
patch 8.2.3126: Vim9: for loop error reports wrong line number
...
Problem: Vim9: for loop error reports wrong line number.
Solution: Save and restore the line number when evaluating the expression.
(closes #8514 )
2021-07-08 19:22:12 +02:00
Bram Moolenaar
4197828dc6
patch 8.2.3099: Vim9: missing catch/finally not reported at script level
...
Problem: Vim9: missing catch/finally not reported at script level.
Solution: Give an error. (closes #8487 )
2021-07-04 14:47:30 +02:00
Bram Moolenaar
e8c4660a55
patch 8.2.2725: Vim9: message about compiling is wrong when using try/catch
...
Problem: Vim9: message about compiling is wrong when using try/catch.
Solution: Store the compiling flag with the message. (closes #8071 )
2021-04-05 22:27:37 +02:00
Bram Moolenaar
522eefd9a2
patch 8.2.2657: Vim9: error message for declaring variable in for loop
...
Problem: Vim9: error message for declaring variable in for loop.
Solution: Clear variables when entering block again. (closes #8012 )
2021-03-26 18:49:22 +01:00
Bram Moolenaar
fa984418e7
patch 8.2.2652: Vim9: can use command modifier without an effect
...
Problem: Vim9: can use command modifier without an effect.
Solution: Give an error for a misplaced command modifier. Fix error message
number.
2021-03-25 22:15:28 +01:00
Bram Moolenaar
0abc6e471a
patch 8.2.2553: Vim9: Cannot put "|" after "{"
...
Problem: Vim9: Cannot put "|" after "{".
Solution: Add the EX_TRLBAR flag. (issue #7904 )
2021-02-26 22:21:23 +01:00
Bram Moolenaar
3e492c2d5f
patch 8.2.2417: condition stack values may be used when not set
...
Problem: Condition stack values may be used when not set.
Solution: Clear cs_script_var_len and cs_block_id just in case they get used
later. (issue #7733 )
2021-01-27 21:37:13 +01:00
Bram Moolenaar
e5a2dc87fd
patch 8.2.2289: Vim9: 'cpo' can become empty
...
Problem: Vim9: 'cpo' can become empty.
Solution: Use empty_option instead of an empty string. Update quickfix
buffer after restoring 'cpo'. (closes #7608 )
2021-01-03 19:52:05 +01:00
Bram Moolenaar
13656f02e4
patch 8.2.2163: crash when discarded exception is the current exception
...
Problem: Crash when discarded exception is the current exception.
Solution: Compare the execption with current_exception. (closes #7499 )
2020-12-19 17:55:54 +01:00
Bram Moolenaar
39ca4127a0
patch 8.2.1870: Vim9: no need to keep all script variables
...
Problem: Vim9: no need to keep all script variables.
Solution: Only keep script variables when a function was defined that could
use them. Fix freeing static string on exit.
2020-10-20 14:25:07 +02:00
Bram Moolenaar
fbbcd00367
patch 8.2.1846: Vim9: block variables are not found in compiled function
...
Problem: Vim9: variables declared in a local block are not found in
when a function is compiled.
Solution: Look for script variables in sn_all_vars.
2020-10-15 12:46:44 +02:00
Bram Moolenaar
8d739de43b
patch 8.2.1845: Vim9: function defined in a block can't use block variables
...
Problem: Vim9: function defined in a block can't use variables defined in
that block.
Solution: First step: Make a second hashtab that holds all script variables,
also block-local ones, with more information.
2020-10-14 19:39:19 +02:00
Bram Moolenaar
9becdf2b98
patch 8.2.1826: Vim9: cannot use a {} block at script level
...
Problem: Vim9: cannot use a {} block at script level.
Solution: Recognize a {} block.
2020-10-10 21:33:48 +02:00
Bram Moolenaar
d747548c66
patch 8.2.1825: Vim9: accessing freed memory
...
Problem: Vim9: accessing freed memory.
Solution: Clear sv_name when the variable is deleted.
2020-10-10 20:31:37 +02:00
Bram Moolenaar
fcdc5d83fb
patch 8.2.1824: Vim9: variables at the script level escape their scope
...
Problem: Vim9: variables at the script level escape their scope.
Solution: When leaving a scope remove variables declared in it.
2020-10-10 19:07:09 +02:00
Bram Moolenaar
4f25b1aba0
patch 8.2.1653: expand('<stack>') does not include the final line number
...
Problem: Expand('<stack>') does not include the final line number.
Solution: Add the line nuber. (closes #6927 )
2020-09-10 19:25:05 +02:00
Bram Moolenaar
a5d0423fa1
patch 8.2.1297: when a test fails it's often not easy to see where
...
Problem: When a test fails it's often not easy to see what the call stack
is.
Solution: Add more entries from the call stack in the exception message.
2020-07-26 15:37:02 +02:00
Bram Moolenaar
2d06bfde29
patch 8.2.1281: the "trailing characters" error can be hard to understand
...
Problem: The "trailing characters" error can be hard to understand.
Solution: Add the trailing characters to the message.
2020-07-23 17:16:18 +02:00
Bram Moolenaar
8930caaa1a
patch 8.2.1280: Ex command error cannot contain an argument
...
Problem: Ex command error cannot contain an argument.
Solution: Add ex_errmsg() and translate earlier. Use e_trailing_arg where
possible.
2020-07-23 16:37:03 +02:00
Bram Moolenaar
e6b5324e3a
patch 8.2.1110: Vim9: line continuation does not work in function arguments
...
Problem: Vim9: line continuation does not work in function arguments.
Solution: Pass "evalarg" to get_func_tv(). Fix seeing double quoted string
as comment.
2020-07-01 17:28:33 +02:00
Bram Moolenaar
b7a78f7a67
patch 8.2.1080: Vim9: no line break allowed in a for loop
...
Problem: Vim9: no line break allowed in a for loop.
Solution: Skip line breaks in for command.
2020-06-28 18:43:40 +02:00
Bram Moolenaar
e40fbc2ca9
patch 8.2.1071: Vim9: no line break allowed inside a lambda
...
Problem: Vim9: no line break allowed inside a lambda.
Solution: Handle line break inside a lambda in Vim9 script.
2020-06-27 18:06:45 +02:00
Bram Moolenaar
b171fb1790
patch 8.2.1049: Vim9: leaking memory when using continuation line
...
Problem: Vim9: leaking memory when using continuation line.
Solution: Keep a pointer to the continuation line in evalarg_T. Centralize
checking for a next command.
2020-06-24 20:34:03 +02:00
Bram Moolenaar
5409f5d8c9
patch 8.2.1047: Vim9: script cannot use line continuation like :def function
...
Problem: Vim9: script cannot use line continuation like in a :def function.
Solution: Pass the getline function pointer to the eval() functions. Use it
for addition and multiplication operators.
2020-06-24 18:37:35 +02:00
Bram Moolenaar
71ccd03ee8
patch 8.2.0967: unnecessary type casts for vim_strnsave()
...
Problem: Unnecessary type casts for vim_strnsave().
Solution: Remove the type casts.
2020-06-12 22:59:11 +02:00
Bram Moolenaar
25e0f5863e
patch 8.2.0823: Vim9: script reload test is disabled
...
Problem: Vim9: script reload test is disabled.
Solution: Compile a function in the context of the script where it was
defined. Set execution stack for compiled function. Add a test
that an error is reported for the right file/function.
2020-05-25 22:36:50 +02:00
Bram Moolenaar
32e351179e
patch 8.2.0753: Vim9: expressions are evaluated in the discovery phase
...
Problem: Vim9: expressions are evaluated in the discovery phase.
Solution: Bail out if an expression is not a constant. Require a type for
declared constants.
2020-05-14 22:41:15 +02:00
Bram Moolenaar
2c5ed4e330
patch 8.2.0612: Vim9: no check for space before #comment
...
Problem: Vim9: no check for space before #comment.
Solution: Add space checks.
2020-04-20 19:42:10 +02:00
Bram Moolenaar
6e949784be
patch 8.2.0570: Vim9: no error when omitting type from argument
...
Problem: Vim9: no error when omitting type from argument.
Solution: Enforce specifying argument types.
2020-04-13 17:21:00 +02:00
Bram Moolenaar
e8c4abbbd7
patch 8.2.0502: Vim9: some code is not tested
...
Problem: Vim9: some code is not tested.
Solution: Add more tests. Fix uncovered problems.
2020-04-02 21:13:25 +02:00
Bram Moolenaar
8a7d6542b3
patch 8.2.0149: maintaining a Vim9 branch separately is more work
...
Problem: Maintaining a Vim9 branch separately is more work.
Solution: Merge the Vim9 script changes.
2020-01-26 15:56:19 +01:00
Bram Moolenaar
1a47ae32cd
patch 8.2.0056: execution stack is incomplete and inefficient
...
Problem: Execution stack is incomplete and inefficient.
Solution: Introduce a proper execution stack and use it instead of
sourcing_name/sourcing_lnum. Create a string only when used.
2019-12-29 23:04:25 +01:00
Bram Moolenaar
ddef129160
patch 8.2.0013: not using a typedef for condstack
...
Problem: Not using a typedef for condstack.
Solution: Add a typedef.
2019-12-16 17:10:33 +01:00
Bram Moolenaar
217e1b8359
patch 8.1.2379: using old C style comments
...
Problem: Using old C style comments.
Solution: Use // comments where appropriate.
2019-12-01 21:41:28 +01:00
Bram Moolenaar
67a2deb9cb
patch 8.1.2341: not so easy to interrupt a script programatically
...
Problem: Not so easy to interrupt a script programatically.
Solution: Add the interrupt() function. (Yasuhiro Matsumoto, closes #2834 )
2019-11-25 00:05:32 +01:00
Bram Moolenaar
5843f5f37b
patch 8.1.1891: functions used in one file are global
...
Problem: Functions used in one file are global.
Solution: Add "static". (Yegappan Lakshmanan, closes #4840 )
2019-08-20 20:13:45 +02:00
Bram Moolenaar
25e42231d3
patch 8.1.1807: more functions can be used as a method
...
Problem: More functions can be used as a method.
Solution: Add append(), appendbufline(), assert_equal(), etc.
Also add the :eval command.
2019-08-04 15:04:10 +02:00
Bram Moolenaar
c799fe206e
patch 8.1.1414: alloc() returning "char_u *" causes a lot of type casts
...
Problem: Alloc() returning "char_u *" causes a lot of type casts.
Solution: Have it return "void *". (Mike Williams) Define ALLOC_ONE() to
check the simple allocations.
2019-05-28 23:08:19 +02:00
Bram Moolenaar
964b3746b9
patch 8.1.1384: using "int" for alloc() often results in compiler warnings
...
Problem: Using "int" for alloc() often results in compiler warnings.
Solution: Use "size_t" and remove type casts. Remove alloc_check(), Vim
only works with 32 bit ints anyway.
2019-05-24 18:54:09 +02:00
Bram Moolenaar
32526b3c18
patch 8.1.0779: argument for message functions is inconsistent
...
Problem: Argument for message functions is inconsistent.
Solution: Make first argument to msg() "char *".
2019-01-19 17:43:09 +01:00
Bram Moolenaar
f9e3e09fdc
patch 8.1.0743: giving error messages is not flexible
...
Problem: Giving error messages is not flexible.
Solution: Add semsg(). Change argument from "char_u *" to "char *", also
for msg() and get rid of most MSG macros. (Ozaki Kiichi, closes
#3302 ) Also make emsg() accept a "char *" argument. Get rid of
an enormous number of type casts.
2019-01-13 23:38:42 +01:00
Bram Moolenaar
6dff58f15c
patch 8.1.0443: unnecessary static function prototypes
...
Problem: Unnecessary static function prototypes.
Solution: Remove unnecessary prototypes.
2018-09-30 21:43:26 +02:00
Bram Moolenaar
cae24be4a8
patch 8.0.0705: crash when there is an error in a timer callback
...
Problem: Crash when there is an error in a timer callback. (Aron Griffis,
Ozaki Kiichi)
Solution: Check did_throw before discarding an exception. NULLify
current_exception when no longer valid.
2017-07-10 22:12:10 +02:00
Bram Moolenaar
8a5883b748
patch 8.0.0075
...
Problem: Using number for exception type lacks type checking.
Solution: Use an enum.
2016-11-10 20:20:05 +01:00
Bram Moolenaar
95f096030e
patch 8.0.0074
...
Problem: Cannot make Vim fail on an internal error.
Solution: Add IEMSG() and IEMSG2(). (Domenique Pelle) Avoid reporting an
internal error without mentioning where.
2016-11-10 20:01:45 +01:00
Bram Moolenaar
edf3f97ae2
patch 7.4.2293
...
Problem: Modelines in source code are inconsistant.
Solution: Use the same line in most files. Add 'noet'. (Naruhiko Nishino)
2016-08-29 22:49:24 +02:00
Bram Moolenaar
9ef00be261
patch 7.4.1500
...
Problem: Should_free flag set to FALSE.
Solution: Set it to TRUE. (Neovim 4415)
2016-03-06 14:58:28 +01:00
Bram Moolenaar
768ce2435a
patch 7.4.1282
...
Problem: Crash when evaluating the pattern of ":catch" causes an error.
(Dominique Pelle)
Solution: Block error messages at this point.
2016-02-07 19:46:12 +01:00