在 2020/2/12 下午3:23, JunMa 写道:
Kindly ping

Regards
JunMa
Hi
In captures_temporary, the current implementation fails to handle
component_ref. This causes ice with case co_await A while
operator co_await is defined in base class of A. Also it is necessary
to capture the object of base class as if it is temporary object.

This patch strips component_ref to its base object and check it as usual.

Bootstrap and test on X86_64, is it OK?

Regards
JunMa

gcc/cp
2020-02-12  Jun Ma <ju...@linux.alibaba.com>

        * coroutines.cc (captures_temporary): Strip component_ref
        to its base object.

gcc/testsuite
2020-02-12  Jun Ma <ju...@linux.alibaba.com>

        * g++.dg/coroutines/torture/co-await-15-capture-comp-ref.C: New test.


Reply via email to