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

[temp.deduct.call] p3 Adding "including" to make the meaning clearer #6132

Open
xmh0511 opened this issue Feb 17, 2023 · 0 comments
Open

[temp.deduct.call] p3 Adding "including" to make the meaning clearer #6132

xmh0511 opened this issue Feb 17, 2023 · 0 comments

Comments

@xmh0511
Copy link
Contributor

xmh0511 commented Feb 17, 2023

[temp.deduct.call] p3 says

A forwarding reference is an rvalue reference to a cv-unqualified template parameter that does not represent a template parameter of a class template (during class template argument deduction ([over.match.class.deduct])).

The wording in the parenthesis sounds like it is a specific interpretation of what we mean by "represent a template parameter of a class template". However, "represent a template parameter of a class template" should also have its literal meaning.

template<class T>
struct A{
   void foo(T&&){}
};

The case is not about class template argument deduction.

Improvement

A forwarding reference is an rvalue reference to a cv-unqualified template parameter that does not represent a template parameter of a class template (including during class template argument deduction ([over.match.class.deduct])).

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

No branches or pull requests

1 participant