Skip to content

Port long blocking stream to QCoro

ivan tkachenko requested to merge work/ratijas/coro into master

Due to the nature of the tasks, some algorithm can not be factored out into QFuture and executed on a thread pool. So they had to be split into hunks, interleaved by zero timers (to allow for rendering and other event processing), and executed on the main thread.

Unlike QObject::connect, QCoro does not seem to have a notion of parent or context object for its awaitables, so after each co_await we have to check whether the task has been cancelled or objects (behind QPointers) deleted.

Merge request reports