mirror of
https://github.com/vim/vim.git
synced 2026-04-10 22:23:43 +02:00
runtime(cpp): Fix c++ float and integer literal syntax highlighting
closes: #8939 Co-authored-by: Eisuke Kawashima <e-kwsm@users.noreply.github.com> Signed-off-by: Dominique Pelle <dominique.pelle@gmail.com> Signed-off-by: Christian Brabandt <cb@256bit.org>
This commit is contained in:
committed by
Christian Brabandt
parent
e80a4ed845
commit
335aecd98f
20
runtime/syntax/testdir/input/cpp_numbers.cpp
Normal file
20
runtime/syntax/testdir/input/cpp_numbers.cpp
Normal file
@@ -0,0 +1,20 @@
|
||||
void foo()
|
||||
{
|
||||
{
|
||||
// See https://en.cppreference.com/w/cpp/language/floating_literal
|
||||
double a = 1.0E2;
|
||||
double b = 1.0e2;
|
||||
double c = 1E2;
|
||||
double d = 1e2;
|
||||
|
||||
double e = 0X1ffp10;
|
||||
double f = 0x1ffp10;
|
||||
}
|
||||
|
||||
// See: https://en.cppreference.com/w/cpp/language/integer_literal
|
||||
int a = 0X123;
|
||||
int b = 0x123;
|
||||
|
||||
int c = 0B101;
|
||||
int d = 0b101;
|
||||
}
|
||||
Reference in New Issue
Block a user