Skip to content
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

[stmt.return]/2 example doesn't have an explanation #3379

Closed
LadyNina opened this issue Nov 7, 2019 · 2 comments · Fixed by #4309
Closed

[stmt.return]/2 example doesn't have an explanation #3379

LadyNina opened this issue Nov 7, 2019 · 2 comments · Fixed by #4309
Assignees

Comments

@LadyNina
Copy link

LadyNina commented Nov 7, 2019

in [stmt.return]/2 we have the following example

std::pair<std::string,int> f(const char* p, int x) { return {p,x}; }

It's not all that clear what this example is meant to demonstrate. Can we add some sort of an explanation?

@tkoeppe
Copy link
Contributor

tkoeppe commented Nov 7, 2019

It looks like the example refers to the following parts of the preceding note: "can involve invocation of a constructor" and "if its type differs".

Maybe a comment like // invokes the constructor std::string::string would improve the example?

@jensmaurer jensmaurer added the decision-required A decision of the editorial group (or the Project Editor) is required. label Nov 20, 2019
@jensmaurer
Copy link
Member

Editorial meeting: Example does not seem to be useful. Strike it.

@jensmaurer jensmaurer removed the decision-required A decision of the editorial group (or the Project Editor) is required. label Feb 10, 2020
@jensmaurer jensmaurer self-assigned this Oct 30, 2020
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 a pull request may close this issue.

3 participants