https://gcc.gnu.org/bugzilla/show_bug.cgi?id=85689
Bug ID: 85689 Summary: if constexpr compiles false branch Product: gcc Version: 8.1.0 Status: UNCONFIRMED Severity: normal Priority: P3 Component: c++ Assignee: unassigned at gcc dot gnu.org Reporter: msharov at users dot sourceforge.net Target Milestone: --- int main (void) { if constexpr (false) static_assert (false, "this should not be compiled"); return 0; } g++ 8.1 fails compiling the branch with the static_assert even though if constexpr condition is false. May be the same as #85149, but still present in g++ 8.1.0 on Arch.