2 // P2448 - Relaxing some constexpr restrictions
3 // { dg-do compile { target c++23 } }
4 // { dg-options "-Winvalid-constexpr" }
6 constexpr volatile int i = 10;
11 return i; // { dg-warning "lvalue-to-rvalue conversion of a volatile lvalue" }
14 constexpr int x = bar (); // { dg-error "called in a constant expression" }