You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
When a coroutine is invoked, after initializing its parameters ([expr.call]), a copy is created for each coroutine parameter. For a parameter of type cv T, the copy is a variable of type cv T with automatic storage duration that is direct-initialized from an xvalue of type T referring to the parameter. [...]
Considering the following coroutine:
task<void> f(int& p)
{
...
}
the copy of the parameter p has type int& and it is initialized with an xvalue, which should not be legal.
Is there something else that I might be missing?
Thank you!
The text was updated successfully, but these errors were encountered:
[dcl.fct.def.coroutine] paragraph 13 states the following:
Considering the following coroutine:
the copy of the parameter
p
has typeint&
and it is initialized with an xvalue, which should not be legal.Is there something else that I might be missing?
Thank you!
The text was updated successfully, but these errors were encountered: