[clang] [clang] require template arg list after template kw (PR #80801)

Erick Velez via cfe-commits cfe-commits at lists.llvm.org
Tue Feb 6 13:27:05 PST 2024


================
@@ -868,6 +868,9 @@ def err_requires_expr_in_simple_requirement : Error<
   "requires expression in requirement body; did "
   "you intend to place it in a nested requirement? (add another 'requires' "
   "before the expression)">;
+def err_missing_template_arg_list_after_template_kw : Error<
+  "a template argument list is expected after a name prefixed by the template "
+  "keyword">;
----------------
evelez7 wrote:

> This should be a pedantic warning (maybe defaulting to an error) Otherwise we might break existing (non conforming) code

I've done this by adding this as a warning to the Pedantic diagnostic group, but I've had to increment the number in `test/Misc/warning-flags.c:91`, and there's a rather stern warning about not adding to `-Wpedantic`. Would this be ok?

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


More information about the cfe-commits mailing list