coroutines: Avoid a maybe used uninitialized warning. NFC.
This avoids a (bogus) warning that occurs with some bootstrap compilers. gcc/cp/ChangeLog: 2020-05-17 Iain Sandoe <iain@sandoe.co.uk> * coroutines.cc (morph_fn_to_coro): Initialize the gro variable.
This commit is contained in:
parent
4c1b27f961
commit
2b9a271b2d
2 changed files with 6 additions and 1 deletions
|
@ -1,3 +1,7 @@
|
|||
2020-05-17 Iain Sandoe <iain@sandoe.co.uk>
|
||||
|
||||
* coroutines.cc (morph_fn_to_coro): Initialize the gro variable.
|
||||
|
||||
2020-05-16 Iain Sandoe <iain@sandoe.co.uk>
|
||||
|
||||
* coroutines.cc (finish_co_return_stmt): Implement rules
|
||||
|
|
|
@ -4285,7 +4285,8 @@ morph_fn_to_coro (tree orig, tree *resumer, tree *destroyer)
|
|||
tree gro_context_body = push_stmt_list ();
|
||||
bool gro_is_void_p = VOID_TYPE_P (TREE_TYPE (get_ro));
|
||||
|
||||
tree gro, gro_bind_vars = NULL_TREE;
|
||||
tree gro = NULL_TREE;
|
||||
tree gro_bind_vars = NULL_TREE;
|
||||
/* We have to sequence the call to get_return_object before initial
|
||||
suspend. */
|
||||
if (gro_is_void_p)
|
||||
|
|
Loading…
Add table
Reference in a new issue