[libcxx-commits] [PATCH] D113348: [libc++] [test] Eliminate the libcpp-no-if-constexpr feature flag.

Arthur O'Dwyer via Phabricator via libcxx-commits libcxx-commits at lists.llvm.org
Sat Nov 6 11:43:43 PDT 2021


Quuxplusone created this revision.
Quuxplusone added reviewers: ldionne, Mordante, libc++.
Quuxplusone added a project: libc++.
Herald added a subscriber: arichardson.
Quuxplusone requested review of this revision.
Herald added a subscriber: libcxx-commits.
Herald added 1 blocking reviewer(s): libc++.

At this point, every supported compiler that claims a -std=c++17 mode should also support `if constexpr`. This was an issue for GCC 5 and GCC 6, but hasn't been an issue since GCC 7. (Our current minimum supported GCC version, IIUC, is GCC 10 or 11.)


Repository:
  rG LLVM Github Monorepo

https://reviews.llvm.org/D113348

Files:
  libcxx/test/libcxx/debug/containers/db_associative_container_tests.pass.cpp
  libcxx/test/libcxx/debug/containers/db_sequence_container_iterators.multithread.pass.cpp
  libcxx/test/libcxx/debug/containers/db_sequence_container_iterators.pass.cpp
  libcxx/test/libcxx/debug/containers/db_string.pass.cpp
  libcxx/test/libcxx/debug/containers/db_unord_container_tests.pass.cpp
  libcxx/test/libcxx/debug/db_string_view.pass.cpp
  libcxx/utils/libcxx/test/features.py


Index: libcxx/utils/libcxx/test/features.py
===================================================================
--- libcxx/utils/libcxx/test/features.py
+++ libcxx/utils/libcxx/test/features.py
@@ -36,7 +36,6 @@
   Feature(name='-fsized-deallocation',          when=lambda cfg: hasCompileFlag(cfg, '-fsized-deallocation')),
   Feature(name='-faligned-allocation',          when=lambda cfg: hasCompileFlag(cfg, '-faligned-allocation')),
   Feature(name='fdelayed-template-parsing',     when=lambda cfg: hasCompileFlag(cfg, '-fdelayed-template-parsing')),
-  Feature(name='libcpp-no-if-constexpr',        when=lambda cfg: '__cpp_if_constexpr' not in featureTestMacros(cfg)),
   Feature(name='libcpp-no-structured-bindings', when=lambda cfg: '__cpp_structured_bindings' not in featureTestMacros(cfg)),
   Feature(name='libcpp-no-concepts',            when=lambda cfg: featureTestMacros(cfg).get('__cpp_concepts', 0) < 201907),
   Feature(name='has-fobjc-arc',                 when=lambda cfg: hasCompileFlag(cfg, '-xobjective-c++ -fobjc-arc') and
Index: libcxx/test/libcxx/debug/db_string_view.pass.cpp
===================================================================
--- libcxx/test/libcxx/debug/db_string_view.pass.cpp
+++ libcxx/test/libcxx/debug/db_string_view.pass.cpp
@@ -8,7 +8,6 @@
 
 // UNSUPPORTED: c++03, c++11, c++14
 // UNSUPPORTED: windows
-// UNSUPPORTED: libcpp-no-if-constexpr
 
 // ADDITIONAL_COMPILE_FLAGS: -D_LIBCPP_DEBUG=1
 // UNSUPPORTED: libcxx-no-debug-mode
Index: libcxx/test/libcxx/debug/containers/db_unord_container_tests.pass.cpp
===================================================================
--- libcxx/test/libcxx/debug/containers/db_unord_container_tests.pass.cpp
+++ libcxx/test/libcxx/debug/containers/db_unord_container_tests.pass.cpp
@@ -8,7 +8,6 @@
 
 // UNSUPPORTED: c++03, c++11, c++14
 // UNSUPPORTED: windows
-// UNSUPPORTED: libcpp-no-if-constexpr
 
 // ADDITIONAL_COMPILE_FLAGS: -D_LIBCPP_DEBUG=1
 // UNSUPPORTED: libcxx-no-debug-mode
Index: libcxx/test/libcxx/debug/containers/db_string.pass.cpp
===================================================================
--- libcxx/test/libcxx/debug/containers/db_string.pass.cpp
+++ libcxx/test/libcxx/debug/containers/db_string.pass.cpp
@@ -8,7 +8,6 @@
 
 // UNSUPPORTED: c++03, c++11, c++14
 // UNSUPPORTED: windows
-// UNSUPPORTED: libcpp-no-if-constexpr
 
 // ADDITIONAL_COMPILE_FLAGS: -D_LIBCPP_DEBUG=1
 // UNSUPPORTED: libcxx-no-debug-mode
Index: libcxx/test/libcxx/debug/containers/db_sequence_container_iterators.pass.cpp
===================================================================
--- libcxx/test/libcxx/debug/containers/db_sequence_container_iterators.pass.cpp
+++ libcxx/test/libcxx/debug/containers/db_sequence_container_iterators.pass.cpp
@@ -8,7 +8,6 @@
 
 // UNSUPPORTED: c++03, c++11, c++14
 // UNSUPPORTED: windows
-// UNSUPPORTED: libcpp-no-if-constexpr
 
 // ADDITIONAL_COMPILE_FLAGS: -D_LIBCPP_DEBUG=1
 // UNSUPPORTED: libcxx-no-debug-mode
Index: libcxx/test/libcxx/debug/containers/db_sequence_container_iterators.multithread.pass.cpp
===================================================================
--- libcxx/test/libcxx/debug/containers/db_sequence_container_iterators.multithread.pass.cpp
+++ libcxx/test/libcxx/debug/containers/db_sequence_container_iterators.multithread.pass.cpp
@@ -9,7 +9,6 @@
 // UNSUPPORTED: c++03, c++11, c++14
 // UNSUPPORTED: windows
 // UNSUPPORTED: libcpp-has-no-threads
-// UNSUPPORTED: libcpp-no-if-constexpr
 
 // ADDITIONAL_COMPILE_FLAGS: -D_LIBCPP_DEBUG=1
 // UNSUPPORTED: libcxx-no-debug-mode
Index: libcxx/test/libcxx/debug/containers/db_associative_container_tests.pass.cpp
===================================================================
--- libcxx/test/libcxx/debug/containers/db_associative_container_tests.pass.cpp
+++ libcxx/test/libcxx/debug/containers/db_associative_container_tests.pass.cpp
@@ -8,7 +8,6 @@
 
 // UNSUPPORTED: c++03, c++11, c++14
 // UNSUPPORTED: windows
-// UNSUPPORTED: libcpp-no-if-constexpr
 
 // ADDITIONAL_COMPILE_FLAGS: -D_LIBCPP_DEBUG=1
 // UNSUPPORTED: libcxx-no-debug-mode


-------------- next part --------------
A non-text attachment was scrubbed...
Name: D113348.385289.patch
Type: text/x-patch
Size: 4075 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/libcxx-commits/attachments/20211106/d051a3df/attachment.bin>


More information about the libcxx-commits mailing list