1 // { dg-options "-std=c++17 -fconcepts" } 2 3 template <class T, class U> 4 concept bool Same = __is_same_as(T, U); 5 6 const int i = 0; 7 template <class T> 8 concept bool C = 9 requires { 10 { &i } -> const Same<T>*; 11 }; 12 13 template <C c> f()14constexpr bool f() { return true; } 15 16 static_assert(f<double>(), ""); // { dg-error "" } 17 static_assert(f<int>(), ""); 18