[clang] Raise an error on namespace aliases with qualified names. (PR #86122)

via cfe-commits cfe-commits at lists.llvm.org
Thu Mar 21 07:28:14 PDT 2024


================
@@ -268,6 +268,8 @@ def err_expected_semi_after_namespace_name : Error<
   "expected ';' after namespace name">;
 def err_unexpected_namespace_attributes_alias : Error<
   "attributes cannot be specified on namespace alias">;
+def err_unexpected_qualified_namespace_alias : Error<
+  "unexpected nested name specifier in namespace alias definition">;
----------------
Sirraide wrote:

I’m not sure how many people would know what a ‘nested name specifier’ is—or at least it requires a bit of thinking. Maybe something like ‘namespace alias must be a single identifier’ would be a bit more obvious?

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


More information about the cfe-commits mailing list