]> granicus.if.org Git - clang/commit
[c++20] Implement P0482R6: enable -fchar8_t by default in C++20 mode.
authorRichard Smith <richard-llvm@metafoo.co.uk>
Wed, 14 Nov 2018 21:04:34 +0000 (21:04 +0000)
committerRichard Smith <richard-llvm@metafoo.co.uk>
Wed, 14 Nov 2018 21:04:34 +0000 (21:04 +0000)
commit761a1b5dc47fc195760dd66b6cfdea3924ca3af8
treee7b9a05594ae498f2295805cd5dd76d9ffc8fdf5
parent52daf3b92d0db0617bdc8d4125aaed5e4abe02db
[c++20] Implement P0482R6: enable -fchar8_t by default in C++20 mode.

This unfortunately results in a substantial breaking change when
switching to C++20, but it's not yet clear what / how much we should
do about that. We may want to add a compatibility conversion from
u8 string literals to const char*, similar to how C++98 provided a
compatibility conversion from string literals to non-const char*,
but that's not handled by this patch.

The feature can be disabled in C++20 mode with -fno-char8_t.

git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@346892 91177308-0d34-0410-b5e6-96231b3b80d8
include/clang/Basic/DiagnosticSemaKinds.td
include/clang/Driver/Options.td
lib/Driver/ToolChains/Clang.cpp
lib/Frontend/CompilerInvocation.cpp
lib/Frontend/InitPreprocessor.cpp
lib/Sema/SemaExpr.cpp
lib/Sema/SemaInit.cpp
test/Lexer/cxx-features.cpp
test/SemaCXX/char8_t.cpp
test/SemaCXX/cxx2a-compat.cpp
www/cxx_status.html