https://gcc.gnu.org/bugzilla/show_bug.cgi?id=95111
--- Comment #18 from Avi Kivity <a...@cloudius-systems.com> --- The work-around works if initial_suspend() returns suspend_never or similar. If the lambda is suspended before execution, the reference may dangle.