Is it possible to make noreturn work together with a function call wrapper, like std::invoke:
#include <functional>
[[noreturn]] void foo()
{std::terminate();}
int doStuff()
{std::invoke(foo);}
This results in a warning, but doStuff will not return.