https://gcc.gnu.org/bugzilla/show_bug.cgi?id=67026
--- Comment #1 from Andrew Pinski <pinskia at gcc dot gnu.org> --- GCC does not implement the full C++14 rules for constexpr yet. That is having a return type of void is not implemented yet. It was invalid for C++11 to have a constexpr with void.