Skip to content

Conversation

@frederick-vs-ja
Copy link
Contributor

In the example in [exec.util.cmplsig.trans], the fallback mechanism of add_lvalue_reference_t doesn't make sense, because when set_value_t(Args&...) is an invalid type, set_value_t(add_lvalue_reference_t<Args>...) can't be valid. Although use of add_lvalue_reference_t possibly triggers more accepts-invalid compiler bugs.

Note that other uses of add_lvalue_reference_t are meaningful:

  • For common_with and common_referene, uses of add_lvalue_reference_t are necessary to make common_with<void, void> satisfied.
  • For unique_ptr, it is possible to form a unique_ptr<void, D> whose operator* is well-formed and returns void, as D::pointer can also have an operator* returning void (demo).

@tkoeppe tkoeppe merged commit 1f79f7a into cplusplus:main Jun 17, 2025
0 of 2 checks passed
@frederick-vs-ja frederick-vs-ja deleted the my-set-lvalue-t branch June 17, 2025 23:20
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants