15 lines · cpp
1// RUN: %clang_cc1 -verify %s2 3struct A {4 static constexpr bool x = true;5};6 7template<typename T, typename U>8void f(T, U) noexcept(T::x);9 10template<typename T, typename U>11void f(T, U*) noexcept(T::y); // expected-error {{no member named 'y' in 'A'}}12 13template<>14void f<A>(A, int*); // expected-note {{in instantiation of exception specification}}15