In P0012R1, \"Make exception specifications be part of the type system\",
I see that noexcept
is now becoming a part of the function type.
I
According to cppreference:
Note that a
noexcept
specification on a function is not a compile-time check; it is merely a method for a programmer to inform the compiler whether or not a function should throw exceptions.
So the syntax of your code is valid, but std::terminate will be called when executed.