coroutines: Do not assume parms are named [PR94752].
authorIain Sandoe <iain@sandoe.co.uk>
Sun, 26 Apr 2020 18:34:50 +0000 (19:34 +0100)
committerIain Sandoe <iain@sandoe.co.uk>
Sun, 26 Apr 2020 19:29:51 +0000 (20:29 +0100)
commit29f55115583a0dab6cbac749c4f0804fd88e9536
tree17d248078a09a9bae1f20fcfec4ba15a4899ae65
parent870923cd48e1e715120ff68425437e5b346283a1
coroutines: Do not assume parms are named [PR94752].

Parameters to user-defined coroutines might be unnamed.
In that case, we must synthesize a name for the coroutine
frame copy.

gcc/cp/ChangeLog:

2020-04-26  Iain Sandoe  <iain@sandoe.co.uk>

PR c++/94752
* coroutines.cc (morph_fn_to_coro): Ensure that
unnamed function params have a usable and distinct
frame field name.

gcc/testsuite/ChangeLog:

2020-04-26  Iain Sandoe  <iain@sandoe.co.uk>

PR c++/94752
* g++.dg/coroutines/pr94752.C: New test.
gcc/cp/ChangeLog
gcc/cp/coroutines.cc
gcc/testsuite/ChangeLog
gcc/testsuite/g++.dg/coroutines/pr94752.C [new file with mode: 0644]