[libcxx-commits] [libcxx] [libc++] constexpr deque (PR #129368)

A. Jiang via libcxx-commits libcxx-commits at lists.llvm.org
Sat Mar 1 03:37:10 PST 2025


https://github.com/frederick-vs-ja requested changes to this pull request.

Thanks! This PR should have `Fixes #128656.`, and There are some changes to be done.

1. Add `_LIBCPP_CONSTEXPR_SINCE_CXX26` to functions in `<deque>`.
2. Modify test files (`.pass.cpp`) in the `libcxx/test/std/containers/sequences/deque` subdirectory. The following pattern can be used.
```C++
TEST_CONSTEXPR_CXX26 bool test() {
  /* existing contents */
  return false;
}

int main(int, char**) {
  test();
#if TEST_STD_VER >= 26
  static_assert(test());
#endif
}
```
3. Add test macro entry for `__cpp_lib_constexpr_deque` (of value `202502`, also in `<deque>`) in `generate_feature_test_macro_components.py` and then run the script.

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


More information about the libcxx-commits mailing list