diff options
| author | Christian Clason <c.clason@uni-graz.at> | 2025-01-17 18:42:07 +0100 |
|---|---|---|
| committer | Christian Clason <ch.clason+github@icloud.com> | 2025-01-18 08:45:43 +0100 |
| commit | 136cb642a0022fd005481e729dcc917552103322 (patch) | |
| tree | 10bcc7087ae45128eb84d640962ca0103743601d /runtime/ftplugin | |
| parent | c9000a6b13fd6695f6e28a890b82b490a123f25e (diff) | |
| download | rneovim-136cb642a0022fd005481e729dcc917552103322.tar.gz rneovim-136cb642a0022fd005481e729dcc917552103322.tar.bz2 rneovim-136cb642a0022fd005481e729dcc917552103322.zip | |
vim-patch:c2a967a: runtime(c): Update syntax and ftplugin files
- highlight more C keywords, including some from C23
Conditionally highlight C23 features:
- #embed, #elifdef and #elifndef preprocessor directives
- predefined macros
- UTF-8 character constants
- binary integer constants, _BitInt literals, and digit separators
- nullptr_t type and associated constant
- decimal real floating-point, bit precise and char types
- typeof operators
Matchit:
- update for new preprocessor directives
fixes: vim/vim#13667
fixes: vim/vim#13679
closes: vim/vim#12984
https://github.com/vim/vim/commit/c2a967a1b9adca6c929e3dc5c218dfada00059b6
Co-authored-by: Doug Kearns <dougkearns@gmail.com>
Co-authored-by: Albin Ahlbäck <albin.ahlback@gmail.com>
Diffstat (limited to 'runtime/ftplugin')
| -rw-r--r-- | runtime/ftplugin/c.vim | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/runtime/ftplugin/c.vim b/runtime/ftplugin/c.vim index 8b2b784eb4..3b05ce182a 100644 --- a/runtime/ftplugin/c.vim +++ b/runtime/ftplugin/c.vim @@ -39,7 +39,7 @@ endif " When the matchit plugin is loaded, this makes the % command skip parens and " braces in comments properly. if !exists("b:match_words") - let b:match_words = '^\s*#\s*if\(\|def\|ndef\)\>:^\s*#\s*elif\>:^\s*#\s*else\>:^\s*#\s*endif\>' + let b:match_words = '^\s*#\s*if\%(\|def\|ndef\)\>:^\s*#\s*elif\%(\|def\|ndef\)\>:^\s*#\s*else\>:^\s*#\s*endif\>' let b:match_skip = 's:comment\|string\|character\|special' let b:undo_ftplugin ..= " | unlet! b:match_skip b:match_words" endif |