| Commit message (Collapse) | Author | Age |
|
|
|
|
|
|
|
|
|
|
| |
Before this change, "static inline" functions in headers needed to have
their function attributes specified in a completely different way. The
prototype had to be duplicated, and REAL_FATTR_ had to be used instead
of the public FUNC_ATTR_ names.
TODO: need a check that a "header.h.inline.generated.h" file is not
forgotten when the first "static inline" function with attributes
is added to a header (they would just be silently missing).
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
(#29653)
Problem: moving in the buffer list doesn't work as documented
(SenileFelineS)
Solution: Skip non-help buffers, when run from normal buffers, else
only move from help buffers to the next help buffer (LemonBoy)
As explained in the help section for :bnext and :bprev the commands
should jump from help buffers to help buffers (and from regular ones to
regular ones).
fixes: vim/vim#4478
closes: vim/vim#15198
https://github.com/vim/vim/commit/893eeeb44583ca33276e263165b2a6e50fd297d0
Co-authored-by: LemonBoy <thatlemon@gmail.com>
|
| |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
This expands on the global "don't pay for what you don't use" rules for
these special extmark decorations:
- inline virtual text, which needs to be processed in plines.c when we
calculate the size of text on screen
- virtual lines, which are needed when calculating "filler" lines
- signs, with text and/or highlights, both of which needs to be
processed for the entire line already at the beginning of a line.
This adds a count to each node of the marktree, for how many special
marks of each kind can be found in the subtree for this node. This makes
it possible to quickly skip over these extra checks, when working in
regions of the buffer not containing these kind of marks, instead of
before where this could just be skipped if the entire _buffer_
didn't contain such marks.
|
|
|
|
|
|
| |
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.
|
|
|
|
| |
Reference: https://github.com/neovim/neovim/issues/6371.
|
| |
|
| |
|
| |
|
| |
|
|
|
|
|
| |
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.
|
| |
|
|
|
|
|
| |
Uncrustify is the source of truth where possible.
Remove any redundant checks from clint.py.
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
ml_get_buf() takes a third parameters to indicate whether the
caller wants to mutate the memline data in place. However
the vast majority of the call sites is using this function
just to specify a buffer but without any mutation. This makes
it harder to grep for the places which actually perform mutation.
Solution: Remove the bool param from ml_get_buf(). it now works
like ml_get() except for a non-current buffer. Add a new
ml_get_buf_mut() function for the mutating use-case, which can
be grepped along with the other ml_replace() etc functions which
can modify the memline.
|
|
|
| |
System headers should be included first to prevent naming conflicts.
|
|
|
|
|
|
|
|
|
|
| |
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.
|
|
|
|
|
|
|
|
| |
* refactor: move tabline code to statusline.c
Problem: Tabline code is closely related to statusline, but still left over in drawscreen.c and screen.c.
Solution: Move it to statusline.c.
* refactor: add statusline_defs.h
|
| |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
* refactor: readability-uppercase-literal-suffix
* refactor: readability-named-parameter
* refactor: bugprone-suspicious-string-compare
* refactor: google-readability-casting
* refactor: readability-redundant-control-flow
* refactor: bugprone-too-small-loop-variable
* refactor: readability-non-const-parameter
* refactor: readability-avoid-const-params-in-decls
* refactor: google-readability-todo
* refactor: readability-inconsistent-declaration-parameter-name
* refactor: bugprone-suspicious-missing-comma
* refactor: remove noisy or slow warnings
|
|
|
|
|
|
|
|
|
| |
problem: code for drawing statusline is arbitrarily spreadout between drawscreen.c, screen.c and buffer.c
solution: move it to a new file statusline.c
- rename archaic internal name "status match" to public name "wildmenu"
- showruler() does not show the ruler. it show anything which displays
info about the cursor. Rename it accordingy.
|
|
|
| |
Replace grid.h in screen.h and screen.h in buffer.h with grid_defs.h
|
|
|
|
| |
Mostly avoids including eval.h, ex_cmds2.h and ex_docmd.h in other
headers.
|
|
|
|
| |
Remove unused includes in src/nvim/buffer.c|h using the IWYU library.
Yet another step towards #6371 and #549
|
|
|
|
|
|
| |
Problem: Get E685 and E931 if buffer reload is interrupted.
Solution: Do not abort deleting a dummy buffer. (closes vim/vim#5361)
https://github.com/vim/vim/commit/a6e8f888e7fc31b8ab7233509254fb2e2fe4089f
|
|
|
|
|
|
| |
Problem: Not sufficient parenthesis in preprocessor macros.
Solution: Add more parenthesis.
https://github.com/vim/vim/commit/9dac9b1751dd43c02470cc6a2aecaeea27abcc80
|
| |
|
|
|
|
|
|
|
|
| |
* 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: Still using default option values after using ":badd +1".
Solution: Find a window where options were set. Don't set the window when
using ":badd".
https://github.com/vim/vim/commit/89b693e5627715cde080c3580c7b641c9bf0c06a
|
|
|
|
|
| |
fixes #6635
closes #9693
|
| |
|
|
|
|
|
|
|
|
|
|
|
|
| |
Loading existing files into a buffer is non-trivial and requires a window.
Creating an unnamed emtpy buffer is trivial and safe though, thus worth a
special case.
Change nvim_buf_set_option to use aucmd_prepbuf. This is necessary
to allow some options to be set on a not yet displayed buffer, such
as 'buftype' option.
vim-patch:7.4.1858: Add BLN_NEW to enforce buflist_new creating new buffer
|
|
|
| |
Ref #8474
|
|
|
|
|
|
|
|
| |
Problem: The ":stag" command does not respect 'switchbuf'.
Solution: Check 'switchbuf' for tag commands that may open a new window.
(Ingo Karkat, closes vim/vim#1681) Define macros for the return values
of getfile().
https://github.com/vim/vim/commit/8ad80dea089ffeb1a845199c013e9bb4be1cd22e
|
|
|
|
|
|
|
|
| |
Problem: When creating a bufref, then using :bwipe and :new it might get
the same memory and bufref_valid() returns true.
Solution: Add br_fnum to check the buffer number didn't change.
https://github.com/vim/vim/commit/45e5fd135da5710f24a1acc142692f120f8b0b78
|
|
|
|
|
|
|
| |
Problem: Number variables are not 64 bits while they could be.
Solution: Add the num64 feature. (Ken Takata)
https://github.com/vim/vim/commit/22fcfad29276bd5f317faf516637dcd491b96a12
|
| |
|
| |
|
|
|
|
| |
Also fixes buffer reusage in setmatches() and complete().
|
| |
|
| |
|
| |
|
|
|
|
|
|
|
|
| |
v7.4.2024 changed a few function signatures of functions that we use in
Neovim-specific code, e.g. the API.
Due to that the commit for 7.4.2024 doesn't build on its own, only together with
this commit.
|
|
|
|
|
|
|
|
|
|
| |
Problem: More buf_valid() calls can be optimized.
Solution: Use bufref_valid() instead.
NOTE: Some changes related to channels and the Python and Netbeans interfaces
were obviously left out.
https://github.com/vim/vim/commit/7c0a2f367f2507669560b1a66423155c70d2e75b
|
|
|
|
|
|
|
|
|
|
|
| |
Problem: When there are many errors adding them to the quickfix list takes
a long time.
Solution: Add BLN_NOOPT. Don't call buf_valid() in buf_copy_options().
Remember the last file name used. When going through the buffer
list start from the end of the list. Only call buf_valid() when
autocommands were executed.
https://github.com/vim/vim/commit/8240433f48f7383c281ba2453cc55f10b8ec47d9
|
| |
|
|
|
|
| |
Currently untested and undocumented.
|
|
|
|
|
|
| |
Most internal functions to modify buffers operate on the current buffer and
require temporary switchs. This macro is a temporary workaround until a cleaner
refactoring of the internal API is performed.
|
| |
|
|
|
|
|
|
|
|
| |
This is not an exhaustive commit, it merely ameliorates the situations a
bit. There are quite a few header files that don't include all the types
they use in their function/struct/... definitions. This throws of the
testing infrastructure (but is not such a problem for the main binary that
has the "tumbleweed of includes"-phenomenon).
|