Debian Codegraph @

gcc/testsuite/g++.dg/cpp1y/constexpr-94716.C

raw
1 // PR c++/94716
2 // { dg-do compile { target c++14 } }
3 // { dg-additional-options "-fdelete-null-pointer-checks" }
4
5 template <int> char v = 0;
6 static_assert (&v<2> == &v<2>, "");
7 static_assert (&v<0> != &v<1>, "");
8 constexpr bool a = &v<2> == &v<2>;
9 constexpr bool b = &v<0> != &v<1>;