================ @@ -227,3 +227,20 @@ struct r6 {}; using r6i = r6<int>; // expected-error@-1 {{constraints not satisfied for class template 'r6' [with T = int]}} + +namespace GH73885 { + +template <class> // expected-error {{extraneous}} +template <class T> requires(T{}) +bool e_v = true; + +static_assert(e_v<bool>); + +// We do accept the following as an extension. See Sema::MatchTemplateParametersToScopeSpecifier() +template <> // expected-warning {{extraneous}} +template <class T> requires(T{true}) +constexpr bool e = true; ---------------- zyn0217 wrote:
https://github.com/llvm/llvm-project/issues/99296 https://github.com/llvm/llvm-project/pull/75697 _______________________________________________ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits