| Commit message (Collapse) | Author | Age | Files | Lines |
... | |
|
|
|
|
| |
Problem: Vim9: expression in :substitute is not compiled.
Solution: Use an INSTR instruction if possible. (closes #10334)
|
|
|
|
|
|
| |
Problem: Concatenating more than 2 strings in a :def function is
inefficient.
Solution: Add a count to the CONCAT instruction. (closes #10276)
|
|
|
|
|
| |
Problem: In compiled code len('string') is not inlined.
Solution: Compute the length at compile time if possible. (closes #10065)
|
|
|
|
|
| |
Problem: Coverity warning for using uninitialized variable.
Solution: Initialize variable to NULL.
|
|
|
|
|
| |
Problem: Errors for functions are sometimes hard to read.
Solution: Use printable_func_name() in more places.
|
|
|
|
|
|
|
| |
Problem: Vim9: can't use items from "import autoload" with autoload
directory name.
Solution: Let sn_autoload_prefix overrule sn_import_autoload.
(closes #10054)
|
|
|
|
|
| |
Problem: "import autoload" only works with using 'runtimepath'.
Solution: Also support a relative and absolute file name.
|
|
|
|
|
|
| |
Problem: Vim9: cannot initialize a variable to null_list.
Solution: Give negative count to NEWLIST. (closes #10027)
Also fix inconsistencies in comparing with null values.
|
|
|
|
|
|
| |
Problem: Vim9: cannot use a recursive call in a nested function. (Sergey
Vlasov)
Solution: Define the funcref before compiling the function. (closes #9989)
|
|
|
|
|
| |
Problem: Vim9: incorrect error for shadowing variable.
Solution: Do not pass the context when compiling a referenced function.
|
|
|
|
|
|
|
| |
Problem: Vim9: test for profiling still fails.
Solution: Update flags for profiling and breakpoints when obtaining the
compile type. Do not set the FC_CLOSURE flag for a toplevel
function.
|
|
|
|
|
|
|
|
| |
Problem: A nested function (closure) is compiled for debugging without
context.
Solution: Check if a nested function is marked for debugging before
compiling it. Give an error when trying to compile a closure
without its context. (closes #9951)
|
|
|
|
|
| |
Problem: Vim9: cannot set variables to a null value.
Solution: Add null_list, null_job, etc.
|
|
|
|
|
| |
Problem: Vim9: can still use s:var in a compiled function.
Solution: Disallow using s:var for Vim9 script. (closes #9824)
|
|
|
|
|
| |
Problem: ctx_imports is not used.
Solution: Delete ctx_imports. Add missing dependency.
|
|
|
|
|
| |
Problem: cstack not always passed to where it is needed.
Solution: Pass ctack through functions.
|
|
|
|
|
| |
Problem: Vim9: incomplete test for existing script variable in block.
Solution: Add a couple more tests. Fix uncovered problem.
|
|
|
|
|
| |
Problem: Vim9: cannot change type of list after making a slice.
Solution: Adjust the declared member type. (closes #9696)
|
|
|
|
|
|
| |
Problem: Vim9: not all code covered by tests.
Solution: Add a few more tests for corner cases. Fix hang when single quote
is missing.
|
|
|
|
|
| |
Problem: list-dict test crashes.
Solution: Check declared type for add().
|
|
|
|
|
|
| |
Problem: Vim9: can still use a global function without g: at the script
level.
Solution: Also check for g: at the script level. (issue #9637)
|
|
|
|
|
|
|
|
| |
Problem: Vim9: finding global function without g: prefix but not finding
global variable is inconsistent.
Solution: Require using g: for a global function. Change the vim9.vim
script into a Vim9 script with exports. Fix that import in legacy
script does not work.
|
|
|
|
|
|
| |
Problem: Vim9: cannot use a function from an autoload import directly.
Solution: Add the AUTOLOAD instruction to figure out at runtime.
(closes #9620)
|
|
|
|
|
| |
Problem: Vim9: warning for missing white space after imported variable.
Solution: Do not skip white space. (closes #9567)
|
|
|
|
|
|
| |
Problem: Vim9: shadowed function can be used in compiled function but not
at script level.
Solution: Also give an error in a compiled function. (closes #9563)
|
|
|
|
|
|
| |
Problem: Vim9: calling import with and without method is inconsistent.
Solution: Set a flag that a parenthsis follows to compile_load_scriptvar().
Add some more tests. Improve error message.
|
|
|
|
|
| |
Problem: Vim9: method in compiled function may not see script item.
Solution: Make sure not to skip to the next line. (closes #9496)
|
|
|
|
|
|
| |
Problem: Vim9: cannot use a method with a complex expression in a :def
function.
Solution: Implement compiling the expression.
|
|
|
|
|
| |
Problem: "cctx" argument of find_func_even_dead() is unused.
Solution: Remove the argument.
|
|
|
|
|
|
| |
Problem: Vim9: compiling function fails when autoload script is not loaded
yet.
Solution: Depend on runtime loading.
|
|
|
|
|
|
| |
Problem: Vim9: need to prefix every item in an autoload script.
Solution: First step in supporting "vim9script autoload" and "import
autoload".
|
|
|
|
|
| |
Problem: Vim9: reading before the start of the line with "$" by itself.
Solution: Do not subtract one when reporting the error.
|
|
|
|
|
| |
Problem: Vim9: import mechanism is too complicated.
Solution: Do not use the Javascript mechanism but a much simpler one.
|
|
|
|
|
|
|
| |
Problem: Vim9: type checking for list and dict lacks information about
declared type.
Solution: Add dv_decl_type and lv_decl_type. Refactor the type stack to
store two types in each entry.
|
|
|
|
|
| |
Problem: Error messages are spread out.
Solution: Move the last errors from globals.h to errors.h.
|
|
|
|
|
| |
Problem: Error messages are spread out.
Solution: Move more errors to errors.h.
|
|
|
|
|
| |
Problem: Error messages are spread out.
Solution: Move more errors to errors.h.
|
|
|
|
|
|
| |
Problem: Help for expressions does not mention Vim9 syntax.
Solution: Add the rules for Vim9 to the expression help. Rename functions
to match the help.
|
|
|
|
|
|
| |
Problem: Vim9: type checking for "any" is inconsistent.
Solution: Always use a runtime type check for using "any" for a more
specific type.
|
|
|
|
|
| |
Problem: Vim9: type checking global variables is inconsistent.
Solution: Use the "unknown" type in more places.
|
|
Problem: Vim9: codecov struggles with the file size.
Solution: Split vim9compile.c into four files.
|