P2781R9 `constant_wrapper`
Nobody has claimed this yet.
- Dominant language
- C++
- Stars
- 11.1k
- Forks
- 1.7k
- Avg merge
- 4d 15h
- Merged PRs (30d)
- 22
Description
WG21-P2781R9 constant_wrapper
WG21-P3978R3 constant_wrapper Should Unwrap On Call And Subscript
WG21-P4206R0 Revert String Support In constant_wrapper
LWG-4351 integral-constant-like needs more remove_cvref_t
LWG-4383 constant_wrapper's pseudo-mutators are underconstrained
LWG-4468 [const.wrap.class] operator decltype(auto) is ill-formed
LWG-4500 constant_wrapper wording problems
LWG-4523 constant_wrapper should assign to value
Feature-test macro:
#define __cpp_lib_constant_wrapper 202606L
Note: We are not yet accepting PRs for C++26 features.
Also note: WG21-P4206R0 updated the feature-test macro value and said it should be applied "As a DR against C++26". While it wasn't formally voted in that way during the June 2026 meeting in Brno, treating it as a DR is obvious, so I've fused that paper into this tracking issue.
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Start by reading the WG21-P2781R9 paper and the listed follow-up papers and LWG issues to understand the required constant_wrapper behavior and feature-test macro. The issue names no source files or tests, and it explicitly says that PRs for C++26 features are not yet accepted, so completion criteria and an implementation entry point require maintainer guidance.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- cpp
- Domain
- compilers
- Issue type
- Feature
- Difficulty
- 5/5
- Estimated time
- Over a week
- Activity status
- Active
- Clarity
- Needs clarification
- Newbie friendliness
- 25/100