Does the backend output c++20?
If so, why? I’m curious what specific features you guys are using from c++20.
Have c++20 coroutines been useful at all?
Have c++20 coroutines been useful at all?
The main motivation wasn't a particular C++20 feature, but using GCC, Clang and MSVC as a portable optimization and code generation backend instead of LLVM or custom machine code generation.
As for coroutines, no. Clx doesn't use C++20 coroutines because Lua coroutines are stackful, so the runtime uses platform-specific context switching instead.
In practice, the code generator doesn't rely heavily on C++20-only features, so targeting C++17 would likely be possible with some adjustments.