-
Notifications
You must be signed in to change notification settings - Fork 771
Qualify all calls to std::get #5556
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
base: main
Are you sure you want to change the base?
Conversation
@jwakely Does this needs an LWG issue or is it sufficiently editorial? |
1dc74eb
to
5433370
Compare
There have been some discussions and confusion about whether `std::get` can be specialized for user types. It can't, it's not a customization point and the standard always calls it qualified. As the issue has come around a few times, the standard should make it clear that this calls is always qualified, like it does for std::move and std::forward.
5433370
to
a726bc7
Compare
Please review the failed checks: there are now some overfull @jwakely , do you want to make this happen? |
I think Corentin's rationale is sound. I think some people might object on the basis that they want to see us not qualifying |
"Some people" here, objecting as expected =) I'm not opposed to explicitly qualifying names, I'm opposed to explicitly qualifying some names explicitly while at the same time explicitly qualifying other names implicitly via blanket wording except for some other names that are implicitly not explicitly qualified so as to enable ADL. It's become nearly impossible to explain to people outside LWG (let alone outside WG21) when and why we qualify names in the library spec. We need to have fewer rules with no exceptions unless our intent is truly that only implementors who attend LWG need to understand. |
@jensmaurer I was planning to wait for lwg to set a direction, but also, I'm afraid my latex is failing me - I tried and looked for different approaches and couldn't find how the standard deals with that in general) What solution do you recommend? |
I know of |
There have been some discussions and confusion about whether
std::get
can be specialized for user types.
It can't, it's not a customization point and the standard always
calls it qualified. As the issue has come around a few times,
the standard should make it clear that this calls is always
qualified, like it does for std::move and std::forward.