diff --git a/runtime/doc/syntax.txt b/runtime/doc/syntax.txt index 26a9baa639..4e4a7b4658 100644 --- a/runtime/doc/syntax.txt +++ b/runtime/doc/syntax.txt @@ -776,6 +776,7 @@ cpp_no_cpp11 don't highlight C++11 standard items cpp_no_cpp14 don't highlight C++14 standard items cpp_no_cpp17 don't highlight C++17 standard items cpp_no_cpp20 don't highlight C++20 standard items +cpp_no_cpp23 don't highlight C++23 standard items CSH *ft-csh-syntax* diff --git a/runtime/syntax/cpp.vim b/runtime/syntax/cpp.vim index 5ea52ec502..1c725a4bfd 100644 --- a/runtime/syntax/cpp.vim +++ b/runtime/syntax/cpp.vim @@ -7,6 +7,7 @@ " 2024 May 04 by Vim Project fix digit separator in octals and floats " 2026 Jan 06 by Vim Project orphaning announcement " 2026 Jan 08 by Vim Project highlight capital letter prefixes for numbers +" 2026 May 29 by Vim Project add C++23 stdfloat types (#16498) " quit when a syntax file was already loaded if exists("b:current_syntax") @@ -104,6 +105,11 @@ if !exists("cpp_no_cpp20") syn keyword cppModule import module export endif +" C++ 23 extensions +if !exists("cpp_no_cpp23") + syn keyword cppType float16_t float32_t float64_t float128_t bfloat16_t +endif + " The minimum and maximum operators in GNU C++ syn match cppMinMax "[<>]?"