I'd like to create a function pointer like this:
void(*function_pointer)()noexcept;
But, this doesn't work. It seems that an exception specifier in a function declaration is invalid. There must be a way to do this though. Right?
This was linked to a question that is not the same as this. Here I'm asking how to create a function pointer with a noexcept specifier. That was not asked or answered in the question "noexcept specifiers in function typedefs".
[except.spec]/2:
So your declaration is indeed well-formed, and Clang compiles it.
Presumably your compiler is not up to date.