Author: Nathan Sidwell Date: 2021-06-09T05:40:53-07:00 New Revision: c1cd743519af3978b944df88f57c6e523caa10dc
URL: https://github.com/llvm/llvm-project/commit/c1cd743519af3978b944df88f57c6e523caa10dc DIFF: https://github.com/llvm/llvm-project/commit/c1cd743519af3978b944df88f57c6e523caa10dc.diff LOG: [clang] p1099 using-enum feature macro & web page This completes the series implementing p1099, by adding the feature macro and updating the web page. Differential Revision: https://reviews.llvm.org/D102242 Added: Modified: clang/lib/Frontend/InitPreprocessor.cpp clang/test/Lexer/cxx-features.cpp clang/www/cxx_status.html Removed: ################################################################################ diff --git a/clang/lib/Frontend/InitPreprocessor.cpp b/clang/lib/Frontend/InitPreprocessor.cpp index 8e63046f4ab22..e03f831c8becb 100644 --- a/clang/lib/Frontend/InitPreprocessor.cpp +++ b/clang/lib/Frontend/InitPreprocessor.cpp @@ -594,7 +594,7 @@ static void InitializeCPlusPlusFeatureTestMacros(const LangOptions &LangOpts, Builder.defineMacro("__cpp_designated_initializers", "201707L"); Builder.defineMacro("__cpp_impl_three_way_comparison", "201907L"); //Builder.defineMacro("__cpp_modules", "201907L"); - //Builder.defineMacro("__cpp_using_enum", "201907L"); + Builder.defineMacro("__cpp_using_enum", "201907L"); } // C++2b features. if (LangOpts.CPlusPlus2b) diff --git a/clang/test/Lexer/cxx-features.cpp b/clang/test/Lexer/cxx-features.cpp index 22ac5567c1d86..8f283dd8c8d9f 100644 --- a/clang/test/Lexer/cxx-features.cpp +++ b/clang/test/Lexer/cxx-features.cpp @@ -98,8 +98,7 @@ #error "wrong value for __cpp_modules" #endif -#if check(using_enum, 0, 0, 0, 0, 0, 0) -// FIXME: 201907 in C++20 +#if check(using_enum, 0, 0, 0, 0, 201907, 201907) #error "wrong value for __cpp_using_enum" #endif diff --git a/clang/www/cxx_status.html b/clang/www/cxx_status.html index 0660816b83c18..fc94282311561 100755 --- a/clang/www/cxx_status.html +++ b/clang/www/cxx_status.html @@ -1205,7 +1205,7 @@ <h2 id="cxx20">C++20 implementation status</h2> <tr> <td><tt>using enum</tt></td> <td><a href="https://wg21.link/p1099r5">P1099R5</a></td> - <td class="none" align="center">No</td> + <td class="unreleased" align="center">Clang 13</td> </tr> <tr> <td rowspan=2>Class template argument deduction for aggregates</td> _______________________________________________ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits