[clang] [Clang] Add [[clang::no_specializations]] (PR #101469)

Erich Keane via cfe-commits cfe-commits at lists.llvm.org
Mon Nov 25 11:48:08 PST 2024


================
@@ -5445,6 +5445,10 @@ def note_dependent_function_template_spec_discard_reason : Note<
   "candidate ignored: %select{not a function template|"
   "not a member of the enclosing %select{class template|"
   "namespace; did you mean to explicitly qualify the specialization?}1}0">;
+def warn_invalid_specialization : Warning<
+  "%0 cannot be specialized%select{|: %2}1">,
+  DefaultError, InGroup<InvalidSpecialization>;
----------------
erichkeane wrote:

```suggestion
  DefaultError, InGroup<DiagGroup<"invalid-specialization">>;
```

https://github.com/llvm/llvm-project/pull/101469


More information about the cfe-commits mailing list