From: Jason Merrill Date: Tue, 17 Dec 2019 21:45:19 +0000 (-0500) Subject: * name-lookup.c (get_std_name_hint): Add std::byte. X-Git-Tag: misc/cutover-git~396 X-Git-Url: http://git.ipfire.org/?a=commitdiff_plain;h=490a091fa7397e34b04e72634c3d37d8a4e223a4;p=thirdparty%2Fgcc.git * name-lookup.c (get_std_name_hint): Add std::byte. From-SVN: r279471 --- diff --git a/gcc/cp/ChangeLog b/gcc/cp/ChangeLog index 6b5849e45b3d..e8a94f463e5b 100644 --- a/gcc/cp/ChangeLog +++ b/gcc/cp/ChangeLog @@ -1,3 +1,7 @@ +2019-12-17 Jason Merrill + + * name-lookup.c (get_std_name_hint): Add std::byte. + 2019-12-17 Jakub Jelinek PR c++/59655 diff --git a/gcc/cp/name-lookup.c b/gcc/cp/name-lookup.c index e64cd9a9d66e..181dad0e2f29 100644 --- a/gcc/cp/name-lookup.c +++ b/gcc/cp/name-lookup.c @@ -5641,6 +5641,8 @@ get_std_name_hint (const char *name) /* . */ {"condition_variable", "", cxx11}, {"condition_variable_any", "", cxx11}, + /* . */ + {"byte", "", cxx17}, /* . */ {"deque", "", cxx98}, /* . */ diff --git a/gcc/testsuite/g++.dg/lookup/missing-std-include-9.C b/gcc/testsuite/g++.dg/lookup/missing-std-include-9.C new file mode 100644 index 000000000000..f8e1e1dd8a7a --- /dev/null +++ b/gcc/testsuite/g++.dg/lookup/missing-std-include-9.C @@ -0,0 +1,3 @@ +std::byte b; // { dg-error "byte" } +// { dg-message "cstddef" "" { target c++17 } .-1 } +// { dg-message "C..17" "" { target c++14_down } .-2 }