You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I am just learning this framework and cpp20; excuse me if this is a known issue/problem.
It seems like there may be an issue in seastar::coroutine::experimental::generator; where both the move constructor and assignment operator do not update the promise object's generator.
Obvious things like this seem to fail. It seems like it is fixed with a couple of lines of changes to the generator class.
auto gen = create_generator(...);
auto gen_moved = std::move(gen);
// usage of gen_moved creates error
However, I seem to get a crash on/off here no matter what. Perhaps my knowledge of coroutines is faulty.
auto gen1 = create1(...);
auto gen2 = create2(..., std::move(gen1));
auto gen3 = create3(..., std::move(gen2));
auto gen4 = create2(..., std::move(gen3));
// start using gen4, which will start gen 1/2/3 upstream.
The text was updated successfully, but these errors were encountered:
@jsong785 thank you for your bug report! this is not a known issue, AFAICT. actually, i never tried to move the generator. will give it a try later on.
The coroutine generator move ctor, move assignment operator,
and swap override were never fully implemented.
This patch completes their implementation
and adds unit tests to cover move and swap
and also moving not-drained generator (to test
moving of their buffered value(s)).
Fixesscylladb#1789
Signed-off-by: Benny Halevy <[email protected]>
The coroutine generator move ctor, move assignment operator,
and swap override were never fully implemented.
This patch completes their implementation
and adds unit tests to cover move and swap
and also moving not-drained generator (to test
moving of their buffered value(s)).
Fixesscylladb#1789
Signed-off-by: Benny Halevy <[email protected]>
I am just learning this framework and cpp20; excuse me if this is a known issue/problem.
It seems like there may be an issue in seastar::coroutine::experimental::generator; where both the move constructor and assignment operator do not update the promise object's generator.
Obvious things like this seem to fail. It seems like it is fixed with a couple of lines of changes to the generator class.
However, I seem to get a crash on/off here no matter what. Perhaps my knowledge of coroutines is faulty.
The text was updated successfully, but these errors were encountered: