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

--- Comment #7 from CVS Commits <cvs-commit at gcc dot gnu.org> ---
The releases/gcc-10 branch has been updated by Iain D Sandoe
<ia...@gcc.gnu.org>:

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

commit r10-9238-gf8214d5381c44f386b0f2c50bb9d48261c9df5a8
Author: Iain Sandoe <i...@sandoe.co.uk>
Date:   Wed Jan 6 19:40:45 2021 +0000

    testsuite, coroutines : Fix a bad testcase [PR96504].

    Where possible (i.e. where that doesn't alter the intent of a test) we
    use a suspend_always as the final suspend and a test that the coroutine
    was 'done' to check that the state machine had terminated correctly.

    Sometimes, filed PRs have 'suspend_never' as the final suspend expression
    and that needs to be changed to match the testsuite style.  This is one
    I missed and means that the call to 'done()' on the handle is made to an
    already-destructed coroutine.  Surprisngly, thAt  didn't actually trigger
    a failure until glibc 2-32.

    Fixed by changing the final suspend to be 'suspend_always'.

    gcc/testsuite/ChangeLog:

            PR c++/96504
            * g++.dg/coroutines/torture/pr95519-05-gro.C: Use suspend_always
            as the final suspend point so that we can check that the state
            machine has reached the expected point.

    (cherry picked from commit 334a295fafdf5e66c4c976874282aea959830eb6)

Reply via email to