8000 Merge pull request #31 from rhysd/cpp14 · WeichenXu/vim-cpp@5132f6d · GitHub
[go: up one dir, main page]

Skip to content

Commit 5132f6d

Browse files
committed
Merge pull request vim-jp#31 from rhysd/cpp14
Added C++14 binary literal highlight
2 parents 98eb6f6 + 7e8ebd3 commit 5132f6d

File tree

1 file changed

+6
-0
lines changed

1 file changed

+6
-0
lines changed

syntax/cpp.vim

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -49,6 +49,11 @@ if !exists("cpp_no_cpp11")
4949
syn region cppRawString matchgroup=cppRawStringDelimiter start=+\%(u8\|[uLU]\)\=R"\z([[:alnum:]_{}[\]#<>%:;.?*\+\-/\^&|~!=,"']\{,16}\)(+ end=+)\z1"+ contains=@Spell
5050
endif
5151

52+
" C++ 14 extensions
53+
if !exists("cpp_no_cpp14")
54+
syn match cppNumber display "\<0b[01]\+\(u\=l\{0,2}\|ll\=u\)\>"
55+
endif
56+
5257
" The minimum and maximum operators in GNU C++
5358
syn match cppMinMax "[<>]?"
5459

@@ -72,6 +77,7 @@ if version >= 508 || !exists("did_cpp_syntax_inits")
7277
HiLink cppConstant Constant
7378
HiLink cppRawStringDelimiter Delimiter
7479
HiLink cppRawString String
80+
HiLink cppNumber Number
7581
delcommand HiLink
7682
endif
7783

0 commit comments

Comments
 (0)
0