| Commit message (Collapse) | Author | Age |
... | |
|
|
|
| |
Work on https://github.com/neovim/neovim/issues/459
|
|
|
|
|
|
|
|
| |
This warning is essentially only triggered for ported vim functions.
It's unlikely that we'll refactor vim functions solely based on their
size since it'd mean we'd greatly deviate from vim, which is a high cost
when it comes to importing the vim patches. Thus, this warning only
serves as an annoyance and should be removed.
|
|
|
|
| |
Work on https://github.com/neovim/neovim/issues/459
|
|
|
|
| |
Work on https://github.com/neovim/neovim/issues/459
|
|
|
|
| |
Work on https://github.com/neovim/neovim/issues/459
|
|
|
| |
Work on https://github.com/neovim/neovim/issues/459
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Add space around arithmetic operators '+' and '-'.
Remove space between back-to-back parentheses, i.e. ')(' vs. ') ('.
Remove space between '((' or '))' of control statements.
Add space between ')' and '{' of control statements.
Remove space between function name and '(' on function declaration.
Collapse empty blocks between '{' and '}'.
Remove newline at the end of the file.
Remove newline between 'enum' and '{'.
Remove newline between '}' and ')' in a function invocation.
Remove newline between '}' and 'while' of 'do' statement.
|
|
|
|
| |
Work on https://github.com/neovim/neovim/issues/567
|
|
|
| |
Closes https://github.com/neovim/neovim/issues/6297
|
|
|
|
|
|
|
|
|
| |
Problem: :endtry after function call that throws not found.
Solution: Do check for following :endtry if an exception is being thrown.
(closes vim/vim#8889)
https://github.com/vim/vim/commit/1d34189ecb99fa76363c06e1aa815c1075675a1c
Nvim obsoleted did_throw; check current_exception is not NULL instead.
|
|
|
|
|
|
|
| |
Problem: Second error is reported while exception is being thrown.
Solution: Do not check for trailing characters when already aborting.
(closes vim/vim#8842)
https://github.com/vim/vim/commit/36f691f5f1d0676f080cc97d697d742ed5cc8251
|
| |
|
| |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
`:verbose` didn't work properly with lua configs (For example:
options or keymaps are set from lua, just say that they were set
from lua, doesn't say where they were set at.
This fixes that issue. Now `:verbose` will provide filename and line no
when option/keymap is set from lua.
Changes:
- compiles lua/vim/keymap.lua as vim/keymap.lua
- When souring a lua file current_sctx.sc_sid is set to SID_LUA
- Moved finding scripts SID out of `do_source()` to `get_current_script_id()`.
So it can be reused for lua files.
- Added new function `nlua_get_sctx` that extracts current lua scripts
name and line no with debug library. And creates a sctx for it.
NOTE: This function ignores C functions and blacklist which
currently contains only vim/_meta.lua so vim.o/opt wrappers aren't
targeted.
- Added function `nlua_set_sctx` that changes provided sctx to current
lua scripts sctx if a lua file is being executed.
- Added tests in tests/functional/lua/verbose_spec.lua
- add primary support for additional types (:autocmd, :function, :syntax) to lua verbose
Note: These can't yet be directly set from lua but once that's possible
:verbose should work for them hopefully :D
- add :verbose support for nvim_exec & nvim_command within lua
Currently auto commands/commands/functions ... can only be defined
by nvim_exec/nvim_command this adds support for them. Means if those
Are defined within lua with vim.cmd/nvim_exec :verbose will show their
location . Though note it'll show the line no on which nvim_exec call was made.
|
|
|
|
|
| |
Possibly dialog code is messages.c could be moved here as well.
misc1.c is now empty, so delete it.
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
* sp_enum_after_assign = force
* sp_brace_typedef = force
* nl_do_brace = remove
* sp_do_brace_open = force
* sp_brace_close_while = force
* sp_before_semi = remove
* sp_before_semi_for = remove
* sp_before_semi_for_empty = remove
* sp_between_semi_for_empty = remove
* sp_after_semi_for_empty = remove
* sp_before_square = remove
* sp_before_squares = remove
* sp_inside_square = remove
* sp_inside_fparens = remove
* sp_inside_fparen = remove
* sp_inside_tparen = remove
* sp_after_tparen_close = remove
* sp_return_paren = force
* pos_bool = lead
* sp_pp_concat = remove
* sp_pp_stringify = remove
* fixup: disable formatting for the INIT section
|
|
|
| |
* refactor: reduce number of explicit char casts
|
|
|
|
|
|
| |
Problem: Argument for message functions is inconsistent.
Solution: Make first argument to msg() "char *".
https://github.com/vim/vim/commit/32526b3c1846025f0e655f41efd4e5428da16b6c
|
|
|
|
|
|
|
|
|
| |
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
vim/vim#3302) Also make emsg() accept a "char *" argument. Get rid of
an enormous number of type casts.
https://github.com/vim/vim/commit/f9e3e09fdc93be9f0d47afbc6c7df1188c2a5a0d
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
* refactor: general good option changes
sp_deref = remove
sp_not = remove
sp_inv = remove
sp_inside_paren_cast = remove
mod_remove_duplicate_include = true
sp_after_semi = add
sp_after_semi_for = force
sp_sizeof_paren = remove
nl_return_expr = remove
nl_else_brace = remove
nl_else_if = remove
* refactor: mod_remove_extra_semicolon = true
* refactor: nl_max = 3
* refactor: sp_bool = force
* refactor: sp_compare = force
* refactor: sp_inside_paren = remove
* refactor: sp_paren_paren = remove
* refactor: sp_inside_sparen = remove
* refactor: sp_before_sparen = force
* refactor: sp_sign = remove
* refactor: sp_addr = remove
* refactor: sp_member = remove
* refactor: nl_struct_brace = remove
* refactor: nl_before_if_closing_paren = remove
* refactor: nl_fdef_brace = force
* refactor: sp_paren_comma = force
* refactor: mod_full_brace_do = add
|
|
|
|
|
|
| |
Problem: Using old C style comments.
Solution: Use // comments where appropriate.
https://github.com/vim/vim/commit/e38eab22c1fb950127f0307a9904de6d4561dc70
|
| |
|
| |
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
* refactor: format with uncrustify
* fixup(dundar): fix functions comments
* fixup(dundar): remove space between variable and ++/--
* fixup(dundar): better workaround for macro attributes
This is done to be able to better use uncrustify rules for macros
* fixup(justin): make preprocessors follow neovim style guide
|
|
|
| |
* fixup: force exactly one whitespace between type and variable
|
|
|
|
| |
* fix function parameter comments
* remove space after star in function names
|
| |
|
|
|
|
|
|
|
|
|
|
|
| |
Problem: Vim script debugger functionality needs cleanup.
Solution: Move debugger code to a separate file. Add more tests. (Yegappan
Lakshmanan, closes vim/vim#4285)
https://github.com/vim/vim/commit/eead75c5e8e1f965548c55ee3a9388b2cb3afc36
Good to have for eval_expr_restore in v8.2.3417.
Doesn't actually add any tests.
|
| |
|
| |
|
|
|
|
|
|
|
|
|
|
| |
v:lua expressions are represented using vvlua_partial. As v:lua isn't
intended to be called directly, it's given an empty pt_name.
Because of this, calling v:lua directly like "v:lua()" will cause "E117:
Unknown function: ", with an empty name.
Instead, have call_func() show the name "v:lua" in the emsg.
|
|
|
|
|
|
| |
Problem: Negative float before method not parsed correctly.
Solution: Apply "!" and "-" in front of expression before using ->.
https://github.com/vim/vim/commit/9cfe8f6e68de4bfb5942d84f4465de914a747b3f
|
|
|
|
|
|
|
| |
Problem: Confusing error when using a builtin function as method while it
does not support that.
Solution: Add a specific error message.
https://github.com/vim/vim/commit/9174639a82799011cfa0013cbc4c4709b3833bf0
|
|
|
|
|
|
| |
Problem: Using expr->FuncRef() does not work.
Solution: Make FuncRef work as a method.
https://github.com/vim/vim/commit/761fdf01c6e307c448cec2684f8b315ba6d1f454
|
|
|
|
|
|
|
| |
Problem: Cannot use a user defined function as a method.
Solution: Pass the base as the first argument to the user defined function
after "->". (partly by FUJIWARA Takuya)
https://github.com/vim/vim/commit/fcfe1a9b8950b8b211ab3b24d84b17c6847ea43f
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Problem: All builtin functions are global.
Solution: Add the method call operator ->. Implemented for a limited number
of functions.
https://github.com/vim/vim/commit/ac92e25a33c37ec5becbfffeccda136c73b761ac
- Note that to *exactly* port hunk @@ -7376,18 +7444,19 from
handle_subscript(), we need the :scriptversion patches (I have an open
PR for those, but this patch works fine without them anyway).
- Port call_internal_func() from v7.4.2058.
- Adjust some error messages in tests, as they rely on the Blob patches.
- Add a modeline to test_method.vim.
Ignore the global_functions and base_method tables and prefer the
current GPerf implementation. Instead, add an extra base_arg field to
VimLFuncDef that holds the number of the argument to use as the base
(1-indexed, so that 0 may be used to refer to functions that cannot be
used as methods).
This also means we support using any argument as a base from the get-go,
rather than just the first (Vim includes this ability in future patches,
however).
To mark a function as usable as a method, use the "base" key as
described in eval.lua.
|
|
|
|
|
|
|
|
|
|
| |
Problem: Function call functions have too many arguments.
Solution: Pass values in a funcexe_T struct.
https://github.com/vim/vim/commit/c6538bcc1cdd1fb83732f22fdc69bd9bb66f968a
Use FUNCEXE_INIT to initialize funcexe_T instances.
call_callback() and other Vim listener related stuff is N/A.
|
| |
|
|
|
|
|
| |
Problem: Garbage collection has useless code.
Solution: Bail out when aborting. (closes vim/vim#8504)
https://github.com/vim/vim/commit/20cc52832067d22a3cd47dfb0805251228c32e7d
|
| |
|
|
|
|
|
|
| |
Problem: Can modify a:000 when using a reference.
Solution: Make check for locked variable stricter. (Ozaki Kiichi,
closes vim/vim#3930)
https://github.com/vim/vim/commit/05c00c038bc16e862e17f9e5c8d5a72af6cf7788
|
|
|
|
| |
vim_strsave() returns nonnull.
|
|
|
|
|
| |
Since we're printf()ing into an offset of fname_buf, we need to reduce
the max length by the same amount.
|
|
|
|
|
|
| |
Problem: Memory leak when default function argument is allocated.
Solution: Free the expression result.
https://github.com/vim/vim/commit/b47bed2f7ada4dfae78f76f27473b83507e40315
|
| |
|
|
|
|
|
|
|
| |
Problem: Named function arguments are never optional.
Solution: Support optional function arguments with a default value. (Andy
Massimino, closes vim/vim#3952)
https://github.com/vim/vim/commit/42ae78cfff171fbd7412306083fe200245d7a7a6
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Problem: Many type casts are used for vim_strnsave().
Solution: Make the length argument size_t instead of int. (Ken Takata,
closes vim/vim#5633) Remove some type casts.
https://github.com/vim/vim/commit/df44a27b53586fccfc6a3aedc89061fdd9a515ff
N/A patches for version.c:
vim-patch:8.2.0315: build failure on HP-UX system
Problem: Build failure on HP-UX system.
Solution: Use LONG_LONG_MIN instead of LLONG_MIN. Add type casts for switch
statement. (John Marriott)
https://github.com/vim/vim/commit/c593bec4120f122e8a9129ec461968f1bd214435
vim-patch:8.2.1052: build failure with older compilers
Problem: Build failure with older compilers.
Solution: Move declaration to start of block.
https://github.com/vim/vim/commit/7acde51832f383f9a6d2e740cd0420b433ea841a
vim-patch:8.2.2229: build failure without the +eval feature
Problem: build failure without the +eval feature.
Solution: Add #ifdef.
https://github.com/vim/vim/commit/39cb2dab18e85fc60f116a4543e433616872b690
vim-patch:8.2.2232: compiler error for falling through into next case
Problem: Compiler error for falling through into next case.
Solution: Move FALLTHROUGH below the #endif
https://github.com/vim/vim/commit/9618a25b9c054f0ee4e267d2db96b6e7c113ed7a
|
|
|
|
|
|
| |
Problem: Memory leak when heredoc is not terminated.
Solution: Free heredoc_trimmed.
https://github.com/vim/vim/commit/fffdf4754f4fd789c64596bdd9ea069725e63784
|
| |
|
|
|
|
|
|
| |
Problem: Coverity complains about ignoring return value.
Solution: Add (void).
https://github.com/vim/vim/commit/d1e9dc272355fe3ab112af5f04b0516b2e9a4fa6
|