| Commit message (Collapse) | Author | Age |
| |
|
|
|
|
|
|
| |
Problem: Line comment start is also found in a string.
Solution: Skip line comments in a string.
https://github.com/vim/vim/commit/ba26367fea3b63df49d274f3d5cca0af38402add
|
|
|
|
|
|
|
| |
Problem: No proper formatting of a C line comment after a statement.
Solution: Find the start of the line comment, insert the comment leader and
indent the comment properly.
https://github.com/vim/vim/commit/6e371ecb27227ff8fedd8561d0f3880a17576848
|
|\
| |
| | |
vim-patch:8.1.{1434,1585},8.2.{3482,3625,3876}: some cindent patches
|
| |
| |
| |
| |
| |
| | |
Problem: 'cindent' does not recognize inline namespace.
Solution: Skip over "inline" to find "namespace". (closes vim/vim#9383)
https://github.com/vim/vim/commit/f2f0bddf303e37d4d532ca22e2d53179c20b1d19
|
| |
| |
| |
| |
| |
| | |
Problem: Illegal memory access when C-indenting.
Solution: Also set the cursor column.
https://github.com/vim/vim/commit/2de9b7c7c8791da8853a9a7ca9c467867465b655
|
| |
| |
| |
| |
| |
| | |
Problem: Reading beyond end of line ending in quote and backslash.
Solution: Check for non-NUL after backslash. (closes vim/vim#8964)
https://github.com/vim/vim/commit/78e0fa4cf4fcd563c0bc8c87afa54d4f5dc22020
|
| | |
|
|/
|
|
|
|
|
|
|
| |
* vim-patch:8.2.3914: various spelling mistakes in comments
Problem: Various spelling mistakes in comments.
Solution: Fix the mistakes. (Dominique Pellé, closes vim/vim#9416)
https://github.com/vim/vim/commit/af4a61a85d6e8cacc35324f266934bc463a21673
Co-authored-by: zeertzjq <zeertzjq@outlook.com>
|
|
|
|
|
| |
Possibly dialog code is messages.c could be moved here as well.
misc1.c is now empty, so delete it.
|
|
|
|
|
|
|
|
| |
* 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
|
|
|
|
| |
"void" cast unused return value of find_last_paren().
|
|
|
|
|
|
| |
Problem: Using old style comments in new file.
Solution: Convert to // comments in new file. (Yegappan Lakshmanan)
https://github.com/vim/vim/commit/9c46efd7dc57c1a8eae5137d05c7e67c4f82c3d7
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Problem: Pragmas are indented all the way to the left.
Solution: Add an option to indent progmas like normal code. (Max Rumpf,
closes vim/vim#5468)
https://github.com/vim/vim/commit/d881b516da0184052d2f9d33c3f72c5c014316bd
N/A patches for version.c:
vim-patch:8.1.2030: tests fail when build with normal features and terminal
Problem: Tests fail when build with normal features and terminal.
(Dominique Pelle)
Solution: Disable tests that won't work. (closes vim/vim#4932)
https://github.com/vim/vim/commit/997d42427eaab889058eb047e08d55de9e4a968a
vim-patch:8.1.2063: some tests fail when +balloon_eval_term is missing
Problem: Some tests fail when +balloon_eval_term is missing but
_balloon_eval is present. (Dominique Pelle)
Solution: Check the right feature in the test. (closes vim/vim#4962)
https://github.com/vim/vim/commit/1e82a784ace6d2c4dce594dd6156bcb0028bba9e
vim-patch:8.2.1938: wiping out a terminal buffer makes some tests fail
Problem: Wiping out a terminal buffer makes some tests fail.
Solution: Do not wipe out the terminal buffer unless wanted.
https://github.com/vim/vim/commit/a46765a79745ff27b4a44659fb8389519c961977
|
| |
|
|
|
|
|
|
| |
Problem: Illegal memory access when using 'cindent'.
Solution: Check for NUL byte. (Dominique Pelle, closes vim/vim#5470)
https://github.com/vim/vim/commit/02ad46394e8f887b60fda994f8a5da2ac1937b23
|
| |
|
|
|
|
|
|
|
|
|
|
|
|
| |
Problem:
During a refactor long ago, we changed the `getdigits_*` familiy of
functions to abort on overflow. But this is often wrong, because many
of these codepaths are handling user input.
Solution:
Decide at each call-site whether to use "strict" mode.
fix #5555
|
| |
|
| |
|
|
|
|
|
|
| |
Problem: Indenting raw C++ strings is wrong.
Solution: Add special handling of raw strings. (Christian Brabandt)
https://github.com/vim/vim/commit/dde81312b031211752d1fcb8539d79f90f324a2e
|
|
|
|
|
|
|
| |
vim-patch:8.0.0431: 'cinoptions' cannot set indent for extern block
Problem: 'cinoptions' cannot set indent for extern block.
Solution: Add the "E" flag in 'cinoptions'. (Hirohito Higashi)
https://github.com/vim/vim/commit/7720ba8599162fbbb8f7fc034f674a2ccd3ca7f1
|
|
|
|
|
|
|
|
| |
Problem: The effect of adding "vim/vim#" to 'cinoptions' is not always removed.
(David Briscoe)
Solution: Reset b_ind_hash_comment. (Christian Brabandt, closes vim/vim#1475)
https://github.com/vim/vim/commit/6b64394f346594404cffb9591d71ac693040679f
|
|
|
|
|
|
|
|
|
| |
Problem: When a C preprocessor statement has two line continuations the
following line does not have the right indent. (Ken Takata)
Solution: Add the indent of the previous continuation line. (Hirohito
Higashi)
https://github.com/vim/vim/commit/c6aa475a27e3ed1645446b014c32ebf68d005d49
|
|
|
|
|
|
|
|
| |
Problem: C indenting does not support nested namespaces that C++ 17 has.
Solution: Add check that passes double colon inside a name. (Pauli, closes
vim/vim#1214)
https://github.com/vim/vim/commit/ca8b8d6956dd881de6446fc32c38e817a364a6cc
|
|
|
|
|
|
|
| |
Problem: Invalid memory access when formatting. (Dominique Pelle)
Solution: Make sure cursor line and column are associated.
https://github.com/vim/vim/commit/80c3fd7c559c7d329d57afe10db9bfb0adf10e46
|
| |
|
| |
|
|
|
|
| |
Also fixed an error in path_fnamecmp().
|
| |
|
|
|
|
|
|
|
|
|
|
| |
move `call_shell` to misc1.c
Move some fns to state.c
Move some fns to option.c
Move some fns to memline.c
Move `vim_chdir*` fns to file_search.c
Move some fns to new module, bytes.c
Move some fns to fileio.c
|
|
|
|
| |
Originally there were 128 new errors, so I thought this is a good idea to fix
all of them. Of course, this commit also fixes many suppressed errors.
|
|
|
|
|
|
|
| |
Problem: Wrong indenting for C++ constructor.
Solution: Recognize ::. (Anhong)
https://github.com/vim/vim/commit/e01f4f86cef7bed3cb99b26f9f57d86f6eb5fe1a
|
|
|
|
|
|
|
|
| |
Problem: C indenting is wrong below a "case (foo):" because it is
recognized as a C++ base class construct. Issue #38.
Solution: Check for the case keyword.
https://github.com/vim/vim/commit/d1b15dec4d00d7ed5e92ff4e0fb7fc2e0818e479
|
|
|
|
|
|
|
|
| |
Problem: Indentation of array initializer is wrong.
Solution: Avoid that calling find_start_rawstring() changes the position
returned by find_start_comment(), add a test. (Hirohito Higashi)
https://github.com/vim/vim/commit/089af18d1fd0961ff504ee72db0156bbfe509cdf
|
| |
|
| |
|
|
|
|
|
|
|
| |
Problem: C indent does not support C11 raw strings. (Mark Lodato)
Solution: Do not change indent inside the raw string.
https://github.com/vim/vim/commit/f7bb86dc593913d055e4cce16cec43f6271adda3
|
| |
|
|
|
|
|
|
|
| |
Problem: For indenting, finding the C++ baseclass can be slow.
Solution: Cache the result. (Hirohito Higashi)
https://github.com/vim/vim/commit/4032cfdf17c1c744d0f87219924870378b86a1c4
|
|
|
|
|
|
|
| |
Problem: Using 'cindent' for Javascript is less than perfect.
Solution: Improve indenting of continuation lines. (Hirohito Higashi)
https://github.com/vim/vim/commit/dcefba993456263100785f18d21d780cf531f2dc
|
| |
|
| |
|
|
|
|
|
|
| |
We already use wrappers for allocation, the new `xfree` function is the
equivalent for deallocation and provides a way to fully replace the malloc
implementation used by Neovim.
|
|
|
|
|
|
|
|
|
|
|
|
| |
Refactor summary:
- foldinfo_T.fi_lnum: int --> linenr_T
Reorder field for optimal packing.
- foldAddMarker(..., markerlen): int --> size_t
* foldstartmarkerlen: int --> size_t
- foldDelMarker(..., markerlen): int --> size_t
* foldendmarkerlen: int --> size_t
Helped-by: oni-link <knil.ino@gmail.com>
|
| |
|
|
|
|
|
|
|
|
|
|
|
| |
This hoists the initialization of `our_paren_pos` outside a conditional
so it can be safely referenced further down in this function.
Originally broken in:
https://code.google.com/p/vim/source/diff?spec=svndc8197342755fda6ca4d6619dac228406867a7ce&old=01583c79d5f4d3f29d4c33dd10dd29efd349cad0&r=dc8197342755fda6ca4d6619dac228406867a7ce&format=unidiff&path=%2Fsrc%2Fmisc1.c
This fixes CID #102151
https://scan8.coverity.com/reports.htm#v22612/p10672/fileInstanceId=3625174&defectInstanceId=1525719&mergedDefectId=102151
|
| |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Problem : getdigits() currently returns a long, but at most places,
return value is casted (unsafely) into an int. Making casts
safe would introduce a lot of fuss in the form of assertions
checking for limits.
Note : We cannot just change return type to int, because, at some
places, legitimate long values are used. For example, in
diff.c, for line numbers.
Solution : Introduce new functions:
- get_digits() : Gets an intmax_t from a string.
- get_int_digits() : Wrapper for ints.
- get_long_digits() : Wrapper for longs.
And replace getdigits() invocations by the appropiate
wrapper invocations.
|
|
|
|
|
|
|
|
| |
Problem: C indent is wrong below an if with wrapped condition followed by
curly braces. (Trevor Powell)
Solution: Make a copy of tryposBrace.
https://code.google.com/p/vim/source/detail?r=v7-4-395
|