-
Notifications
You must be signed in to change notification settings - Fork 260
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
[BUG] Double move when passing by move #413
Comments
I fixed it locally, I don't know if it breaks something else in the process.
I have added :
Let me know if this works or not, I look forward to contributing more actively, but for the time being I'm familiarizing my self with the compiler code. |
I can't know, as I don't have working code. |
My apologies, I was referring to the contributors. |
Now I can confirm that it works, - v = X<19>(); std::cout << "move(v) as X<19> = " + cpp2::to_string(int(cpp2::as_<X<19>>((std::move(std::move(v)))))) << std::endl;
+ v = X<19>(); std::cout << "move(v) as X<19> = " + cpp2::to_string(int(cpp2::as_<X<19>>((std::move(v))))) << std::endl; |
An alternative Expected result |
This isn't true in a generic context. |
Title: Double move when passing by move.
Minimal reproducer (https://cpp2.godbolt.org/z/31sPe9xMj):
Commands:
Expected result:
Actual result and error:
The text was updated successfully, but these errors were encountered: