[libcxx-commits] [libcxx] [libc++][test] Improves C++ Standard filtering. (PR #89499)

Louis Dionne via libcxx-commits libcxx-commits at lists.llvm.org
Tue Dec 3 08:38:10 PST 2024


================
@@ -435,6 +435,38 @@ writing tests easier. See `libc++-specific Lit Directives`_ for more information
        extension.)
 
 
+C++ Standard version tests
+~~~~~~~~~~~~~~~~~~~~~~~~~~
+
+Historically libc++ tests used to filter the tests for C++ Standard versions
+with lit directives like:
+
+.. code-block:: cpp
+
+   // UNSUPPORTED: c++03, c++11, c++14, c++17, c++20, c++23
+
+With C++ Standards released every 3 years, this solution is not scalable.
+Instead use:
+
+.. code-block:: cpp
+
+   // UNSUPPORTED: std-at-least-c++26
----------------
ldionne wrote:

```suggestion
   // REQUIRES: std-at-least-c++26
```

https://github.com/llvm/llvm-project/pull/89499


More information about the libcxx-commits mailing list