Re: Requires clauses in pfn conversions for generic lambdas
Project / Subsystem
gcc / gcc
Date
2026-09-12
Proposer
Waffl3x <waffl3x@protonmail.com>
Source type
public_inbox
Consensus
Proposed
Sentiment
—/10
Technical tradeoffs
- • Strict adherence to the current standard (even if ambiguous) vs. adopting compiler-specific extensions that offer more flexibility.
- • Clarifying the standard via CWG is slow but provides a definitive answer; compiler-specific bug fixes are faster but may lead to inconsistencies.
- • The interaction between generic lambdas, PFN conversion, and requires clauses is complex, requiring careful analysis to ensure correct and consistent behavior.
All attributes
- project
- gcc
- subsystem
- gcc
- patch_id
- —
- discussion_id
- V3AUSQ3beDn7dZBzc5IPO2qaZHlrhvp5-8jwpFVpx0iIYglKIhFeqzTUuNZFRO1R11rRYdO8o1b84cf-It_jG80adLlX7xsupBh0HE3QSCM=@protonmail.com
- source_type
- public_inbox
- title
- Re: Requires clauses in pfn conversions for generic lambdas
- headline
- Requires clauses in pfn conversions for generic lambdas
- tldr
- Discussion on C++ standard's handling of requires clauses in generic lambda pfn conversions, suggesting a CWG issue and a GCC PR for an ICE.
- proposer
- Waffl3x <waffl3x@protonmail.com>
- consensus
- Proposed
- outcome
- proposed
- sentiment_score
- —
- technical_tradeoffs
-
- • Strict adherence to the current standard (even if ambiguous) vs. adopting compiler-specific extensions that offer more flexibility.
- • Clarifying the standard via CWG is slow but provides a definitive answer; compiler-specific bug fixes are faster but may lead to inconsistencies.
- • The interaction between generic lambdas, PFN conversion, and requires clauses is complex, requiring careful analysis to ensure correct and consistent behavior.
- series_id
- —
- series_role
- standalone
- series_parts
- []
- tags
-
- • C++
- • compiler
- • GCC
- • lambda
- • templates
- bugzilla_url
- —
- date
- 2026-09-12T00:00:00.000Z
Re: Requires clauses in pfn conversions for generic lambdas
Following up on a discussion about C++ lambda conversion operators, Alex (Waffl3x) agrees that the standard might be lacking in its description of requires clauses for pointer-to-function conversions of generic lambdas. He suggests opening a Core Working Group (CWG) issue to clarify the standard and advises the original poster to file a bug report for an Internal Compiler Error (ICE) observed in GCC, after checking for duplicates.