https://gcc.gnu.org/bugzilla/show_bug.cgi?id=105406

--- Comment #5 from CVS Commits <cvs-commit at gcc dot gnu.org> ---
The releases/gcc-11 branch has been updated by Jason Merrill
<ja...@gcc.gnu.org>:

https://gcc.gnu.org/g:657fb0db2648a8cd7ba355fdec570fe2f08448ac

commit r11-10642-g657fb0db2648a8cd7ba355fdec570fe2f08448ac
Author: Jason Merrill <ja...@redhat.com>
Date:   Wed Mar 15 17:02:15 2023 -0400

    c++: co_await and move-only type [PR105406]

    Here we were building a temporary MoveOnlyAwaitable to hold the result of
    evaluating 'o', but since 'o' is an lvalue we should build a reference
    instead.

            PR c++/105406

    gcc/cp/ChangeLog:

            * coroutines.cc (build_co_await): Handle lvalue 'o'.

    gcc/testsuite/ChangeLog:

            * g++.dg/coroutines/co-await-moveonly1.C: New test.

Reply via email to