Build coroutine expression with unknown_type in processing_template_decl phase.
authorJunMa <JunMa@linux.alibaba.com>
Wed, 5 Feb 2020 05:46:59 +0000 (13:46 +0800)
committerJunMa <JunMa@linux.alibaba.com>
Tue, 3 Mar 2020 03:18:54 +0000 (11:18 +0800)
commitfd9e021c70edf459e5d700af90bfe005dc0afb3b
tree7c98f9efe3f20176db35955ec725c2583220691c
parent3f33c471bbf745216e0601cb629144b34642c9b9
Build coroutine expression with unknown_type in processing_template_decl phase.

gcc/cp
        * coroutines.cc (finish_co_await_expr): Build co_await_expr
        with unknown_type_node.
        (finish_co_yield_expr): Ditto.
        *pt.c (type_dependent_expression_p): Set co_await/yield_expr
        with unknown type as dependent.

gcc/testsuite
        * g++.dg/coroutines/torture/co-await-14-template-traits.C: New test.
gcc/cp/ChangeLog
gcc/cp/coroutines.cc
gcc/cp/pt.c
gcc/testsuite/ChangeLog
gcc/testsuite/g++.dg/coroutines/torture/co-await-14-template-traits.C [new file with mode: 0644]