| Commit message (Collapse) | Author | Age |
|
|
|
|
|
|
|
|
|
| |
Problem:
`AucmdExecutable` adds 2 layers of indirection. Although formalizing
a `union` is good practice for shared interfaces, this struct is mainly
for `autocmd_register` which is internal to this module.
Solution:
- Store the cmd/fn fields directly on the `AutoCmd` struct.
- Drop `AucmdExecutable` and related structures.
|
|
|
|
|
|
|
| |
This also makes shada reading slightly faster due to avoiding
some copying and allocation.
Use keysets to drive decoding of msgpack maps for shada entries.
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Problem: POSIX function name in exarg struct causes issues
on OpenVMS
Solution: Rename getline member in exarg struct to ea_getline,
remove isinf() workaround for VMS
There are compilers that do not treat well POSIX functions - like
getline - usage in the structs.
Older VMS compilers could digest this... but the newer OpenVMS compilers
( like VSI C x86-64 X7.4-843 (GEM 50XB9) ) cannot deal with these
structs. This could be limited to getline() that is defined via
getdelim() and might not affect all POSIX functions in general - but
avoiding POSIX function names usage in the structs is a "safe side"
practice without compromising the functionality or the code readability.
The previous OpenVMS X86 port used a workaround limiting the compiler
capabilities using __CRTL_VER_OVERRIDE=80400000
In order to make the OpenVMS port future proof, this pull request
proposes a possible solution.
closes: vim/vim#13704
https://github.com/vim/vim/commit/6fdb6280821a822768df5689a5d727e37d38306c
Co-authored-by: Zoltan Arpadffy <zoltan.arpadffy@gmail.com>
|
|
|
|
|
|
| |
Remove `export` pramgas from defs headers as it causes IWYU to believe
that the definitions from the defs headers comes from main header, which
is not what we really want.
|
|
|
|
| |
A struct can be anonymous if only its typedef is used.
|
| |
|
|
|
|
|
|
|
|
|
|
| |
It isn't really useful to put anonymous enums only used as arguments to
functions calls in _defs.h headers, as they will only be used by a file
that calls those functions, which requires including a non-defs header.
Also move os_msg() and os_errmsg() back to message.h, as on Windows they
are actual functions instead of macros.
Also remove gettext.h and globals.h from private/helpers.h.
|
| |
|
| |
|
| |
|
|
|
|
|
| |
It is less error-prone than manually defining header guards. Pretty much
all compilers support it even if it's not part of the C standard.
|
|
|
|
|
|
| |
long is 32 bits on windows, while it is 64 bits on other architectures.
This makes the type suboptimal for a codebase meant to be
cross-platform. Replace it with more appropriate integer types.
|
| |
|
|
|
|
|
|
|
|
|
|
|
| |
glob() (#25427)
Problem: Custom cmdline completion skips original cmdline when pressing
Ctrl-P at first match if completion function invokes glob().
Solution: Move orig_save into struct expand_T.
closes: vim/vim#13216
https://github.com/vim/vim/commit/28a23602e8f88937645b8506b7915ecea6e09b18
|
|
|
|
|
| |
long is 32-bits even on 64-bit windows which makes the type suboptimal
for a codebase meant to be cross-platform.
|
|
|
|
|
|
|
|
| |
Problem: Rename completion specific findex var
Solution: Move "findex" static variable to xp_selected in expand_T
closes: vim/vim#12548
https://github.com/vim/vim/commit/e9ef347c137aca6c2592beb19da45a8aece65e11
|
|
|
| |
Because typval_defs.h is enough for most of them.
|
|
|
|
|
|
|
|
|
|
|
| |
(#23518)
Problem: Completion for option name includes all bool options.
Solution: Do not recognize the "noinv" prefix. Prefix "no" or "inv" when
appropriate.
https://github.com/vim/vim/commit/048d9d25214049dfde04c468c14bd1708fb692b8
Co-authored-by: Bram Moolenaar <Bram@vim.org>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
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.
https://github.com/vim/vim/commit/b171fb179053fa631fec74911b5fb9374cb6a8a1
Omit eval_next_line(): Vim9 script only.
vim-patch:8.2.1050: missing change in struct
Problem: Missing change in struct.
Solution: Add missing change.
https://github.com/vim/vim/commit/65a8ed37f7bc61fbe5c612a7b0eb0dfc16ad3e11
Co-authored-by: Bram Moolenaar <Bram@vim.org>
|
|
|
|
|
|
|
|
|
|
| |
Allow Include What You Use to remove unnecessary includes and only
include what is necessary. This helps with reducing compilation times
and makes it easier to visualise which dependencies are actually
required.
Work on https://github.com/neovim/neovim/issues/549, but doesn't close
it since this only works fully for .c files and not headers.
|
|
|
|
|
|
|
|
|
|
|
| |
- `:write ++p foo/bar/baz.txt` should create parent directories `foo/bar/` if
they do not exist
- Note: `:foo ++…` is usually for options. No existing options have
a single-char abbreviation (presumably by design), so it's safe to
special-case `++p` here.
- Same for `writefile(…, 'foo/bar/baz.txt', 'p')`
- `BufWriteCmd` can see the ++p flag via `v:cmdarg`.
closes #19884
|
|
|
| |
Co-authored-by: Marco Lehmann <m99@posteo.de>
|
|
|
|
|
|
| |
Problem: Using static buffer for multiple completion functions.
Solution: Use one buffer in expand_T.
https://github.com/vim/vim/commit/5ff595d9db2d9a33aa10cc9f18f256826226862f
|
|
|
|
| |
Co-authored-by: zeertzjq <zeertzjq@outlook.com>
|
| |
|
|
|
|
|
|
|
| |
Problem: Vim9: error when using vim9script in TextYankPost.
Solution: Use EX_LOCKOK instead of the EX_CMDWIN flag for command that can
be used when text is locked. (closes vim/vim#6529)
https://github.com/vim/vim/commit/37394ff75270877a032422abcd079a6732a29730
|
|
|
|
|
|
| |
Also fixes a memory leak in `parse_cmdline`.
Closes #18954.
|
|
|
| |
Work on https://github.com/neovim/neovim/issues/459
|
|
|
|
|
|
|
|
| |
Problem: Value of cmod_verbose is a bit complicated to use.
Solution: Use zero for not set, value + 1 when set. (closes vim/vim#10564)
https://github.com/vim/vim/commit/cd7496382efc9e6748326c6cda7f01003fa07063
Omit has_cmdmod(): only used for Vim9 script
|
|
|
|
|
|
| |
Problem: Command modifier parsing always uses global cmdmod.
Solution: Pass in cmdmod_T to use. Rename struct fields consistently.
https://github.com/vim/vim/commit/e10044015841711b989f9a898d427bcc1fdb4c32
|
| |
|
|
|
|
|
|
|
|
|
| |
Problem: Command modifiers are saved and set inconsistently.
Solution: Separate parsing and applying command modifiers. Save values in
cmdmod_T.
https://github.com/vim/vim/commit/5661ed6c833e05467cab33cb9b1c535e7e5cc570
Cherry-pick: :0verbose fix from patch 8.2.4741
|
|
|
|
| |
Adds a Lua-only `preview` flag to user commands which allows the command to be incrementally previewed like `:substitute` when 'inccommand' is set.
|
|\
| |
| | |
refactor: replace char_u variables and functions with char
|
| |
| |
| |
| | |
Work on https://github.com/neovim/neovim/issues/459
|
|/
|
|
| |
Adds the API function `nvim_cmd` which allows executing an Ex-command through a Dictionary which can have the same values as the return value of `nvim_parse_cmd()`. This makes it much easier to do things like passing arguments with a space to commands that otherwise may not allow it, or to make commands interpret certain characters literally when they otherwise would not.
|
|
|
|
| |
Work on https://github.com/neovim/neovim/issues/459
|
|
|
|
| |
Work on https://github.com/neovim/neovim/issues/459
|
|
|
|
| |
Adds an API function to parse a command line string and get command information from it.
|
|
|
| |
Work on https://github.com/neovim/neovim/issues/459
|
|
|
|
|
|
| |
Problem: Not sufficient parenthesis in preprocessor macros.
Solution: Add more parenthesis.
https://github.com/vim/vim/commit/9dac9b1751dd43c02470cc6a2aecaeea27abcc80
|
| |
|
|
|
|
|
|
|
|
| |
Problem: "verbose set efm" reports the location of the :compiler command.
(Gary Johnson)
Solution: Add the "-keepscript" argument to :command and use it when
defining CompilerSet.
https://github.com/vim/vim/commit/58ef8a31d7087d495ab1582be5b7a22796ac2451
|
|
|
|
|
| |
Add support for adding and removing custom user commands with the Nvim
API.
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
* 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
|
|
|
|
|
|
|
|
|
| |
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: format all C files under nvim
* refactor: disable formatting for Vim-owned files:
* src/nvim/indent_c.c
* src/nvim/regexp.c
* src/nvim/regexp_nfa.c
* src/nvim/testdir/samples/memfile_test.c
|
| |
|
|
|
|
|
|
|
|
|
| |
Problem: Padding in structures wastes memory.
Solution: Move fields to avoid padding. (Dominique Pelle, closes vim/vim#5202)
https://github.com/vim/vim/commit/d6beab0248cdb0b7073e97d98d65de7138cb3386
Skip "ml_line_len" member of "struct memline".
Patch v8.1.0579 was not ported.
|