https://gcc.gnu.org/bugzilla/show_bug.cgi?id=89074
--- Comment #5 from Jonathan Wakely <redi at gcc dot gnu.org> --- I think this is another case of the same bug: constexpr bool test() { int a[] = { 1, 2 }; int b[] = { 3, 4 }; if (a+0 == b+0) // OK return false; if (a+1 == b+0) // ERROR return false; return true; } static_assert( test() ); g++ -std=c++20 ce.C -c ce.C:16:20: error: non-constant condition for static assertion 16 | static_assert( test() ); | ~~~~^~ ce.C:16:20: in 'constexpr' expansion of 'test()' ce.C:10:11: error: '((((int*)(& a)) + 4) == ((int*)(& b)))' is not a constant expression 10 | if (a+1 == b+0) // ERROR | ~~~~^~~~~~