================
@@ -4907,6 +4907,20 @@ void Sema::AddModeAttr(Decl *D, const 
AttributeCommonInfo &CI,
   D->addAttr(::new (Context) ModeAttr(Context, CI, Name));
 }
 
+static void handleNonStringAttr(Sema &S, Decl *D, const ParsedAttr &AL) {
+  // This only applies to fields and variable declarations which have an array
+  // type.
+  QualType QT = cast<ValueDecl>(D)->getType();
+  if (!QT->isArrayType() ||
+      !QT->getBaseElementTypeUnsafe()->isAnyCharacterType()) {
----------------
erichkeane wrote:

Interestingly, GCC allows this in C++ mode (https://godbolt.org/z/o7veGEfs5) 
and we never do.  Not sure if that is something we need to do in the future.

But that means we don't really have to check now.

https://github.com/llvm/llvm-project/pull/137829
_______________________________________________
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

Reply via email to