1 2 3 4 5 6 7 8 9 10 11 12 13 14
// { dg-do compile { target c++20 } } template<class T, class U> concept Same = __is_same_as(T, U); template<typename T> concept C1 = true; template<typename T, typename U> concept C2 = true; C1 auto c1 = 0; C2<int> auto c2 = 0; Same<int> auto s1 = 'a'; // { dg-error "does not satisfy|is_same" }