aboutsummaryrefslogtreecommitdiff
path: root/gcc/c-family/c-cppbuiltin.c
diff options
context:
space:
mode:
authorJason Merrill <jason@redhat.com>2015-10-19 22:48:36 -0400
committerJason Merrill <jason@gcc.gnu.org>2015-10-19 22:48:36 -0400
commit13b380a3257189e5232010c982b8c691b348482c (patch)
tree8f01b250493343703129c8d1fabd0880cd14fc56 /gcc/c-family/c-cppbuiltin.c
parenta36b732a762dd1768b67d6860262903e68c558f9 (diff)
downloadgcc-13b380a3257189e5232010c982b8c691b348482c.zip
gcc-13b380a3257189e5232010c982b8c691b348482c.tar.gz
gcc-13b380a3257189e5232010c982b8c691b348482c.tar.bz2
c-cppbuiltin.c (c_cpp_builtins): Define __cpp_enumerator_attributes...
* c-cppbuiltin.c (c_cpp_builtins): Define __cpp_enumerator_attributes, __cpp_fold_expressions, __cpp_unicode_characters. From-SVN: r229017
Diffstat (limited to 'gcc/c-family/c-cppbuiltin.c')
-rw-r--r--gcc/c-family/c-cppbuiltin.c6
1 files changed, 5 insertions, 1 deletions
diff --git a/gcc/c-family/c-cppbuiltin.c b/gcc/c-family/c-cppbuiltin.c
index 35d246b..cd6fd51 100644
--- a/gcc/c-family/c-cppbuiltin.c
+++ b/gcc/c-family/c-cppbuiltin.c
@@ -833,7 +833,8 @@ c_cpp_builtins (cpp_reader *pfile)
if (cxx_dialect >= cxx11)
{
/* Set feature test macros for C++11. */
- cpp_define (pfile, "__cpp_unicode_characters=200704");
+ if (cxx_dialect <= cxx14)
+ cpp_define (pfile, "__cpp_unicode_characters=200704");
cpp_define (pfile, "__cpp_raw_strings=200710");
cpp_define (pfile, "__cpp_unicode_literals=200710");
cpp_define (pfile, "__cpp_user_defined_literals=200809");
@@ -869,9 +870,12 @@ c_cpp_builtins (cpp_reader *pfile)
if (cxx_dialect > cxx14)
{
/* Set feature test macros for C++1z. */
+ cpp_define (pfile, "__cpp_unicode_characters=201411");
cpp_define (pfile, "__cpp_static_assert=201411");
cpp_define (pfile, "__cpp_namespace_attributes=201411");
+ cpp_define (pfile, "__cpp_enumerator_attributes=201411");
cpp_define (pfile, "__cpp_nested_namespace_definitions=201411");
+ cpp_define (pfile, "__cpp_fold_expressions=201411");
}
if (flag_concepts)
/* Use a value smaller than the 201507 specified in