18 QDebugStateSaver saver { dbg };
19 dbg.nospace () <<
"ProcessFailedToStart { " << failed.
Error_ <<
" }";
25 QDebugStateSaver saver { dbg };
26 dbg.nospace () <<
"ProcessCrashed { code: " << crashed.
Code_ <<
" }";
32 QDebugStateSaver saver { dbg };
33 dbg.nospace () <<
"ProcessExited { code: " << exited.
Code_ <<
" }";
39 Visit (outcome, [&dbg] (
const auto& alternative) { dbg << alternative; });
48 return Process_.state () == QProcess::NotRunning;
53 const auto resumeLater = [
this, handle]
59 QObject::disconnect (std::move (
ErrorConn_).Release ());
68 if (
Process_.error () == QProcess::FailedToStart)
71 if (
Process_.exitStatus () == QProcess::CrashExit)
std::variant< ProcessFailedToStart, ProcessCrashed, ProcessExited > ProcessOutcome
auto Visit(const Either< Left, Right > &either, Args &&... args)
QDebug operator<<(QDebug dbg, const CtString< N, Char > &str)
RaiiSignalConnection FinishedConn_
void await_suspend(std::coroutine_handle<> handle)
RaiiSignalConnection ErrorConn_
ProcessOutcome await_resume() const
bool await_ready() const noexcept