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

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

https://gcc.gnu.org/g:d0ed0690f1e86621a5cb62eec1d144036feb16f8

commit r13-6711-gd0ed0690f1e86621a5cb62eec1d144036feb16f8
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