From 7154aa76c18e89db23092e04b15fb21dc1d54103 Mon Sep 17 00:00:00 2001 From: Vegard Storheil Eriksen Date: Sat, 10 Sep 2022 17:10:34 +0200 Subject: async: Workaround for gcc bug. --- async/scheduler.h | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/async/scheduler.h b/async/scheduler.h index 5c2adaa..35f625e 100644 --- a/async/scheduler.h +++ b/async/scheduler.h @@ -162,6 +162,10 @@ struct task : public schedulable { void return_void() {} }; + // Certain gcc builds hits a corner case triggering an internal error when trying to create a task. + // sizeof(task) == 8 appears to be one of the conditions, so we pad it as a workaround. + uint32_t _dummy; + task(std::coroutine_handle h) : schedulable(h) {} }; -- cgit v1.2.3