/*iterator*/ begin(); | (since C++23) |
Pushes coroutine_ into *active_ stack, then evaluates coroutine_.resume().
Before invocation of begin() the coroutine_ must refer to a coroutine suspended at its initial suspend point.
An iterator whose coroutine_ member refers to the same coroutine as coroutine_ does.
It is an undefined behavior to call begin() more than once on the same generator object.
© cppreference.com
Licensed under the Creative Commons Attribution-ShareAlike Unported License v3.0.
https://en.cppreference.com/w/cpp/coroutine/generator/begin