================
@@ -422,6 +422,28 @@ static const char *getInitializer(QualType QT, bool 
UseAssignment) {
   }
 }
 
+static bool isStdArray(QualType QT) {
+  const auto *RT = QT->getAs<RecordType>();
+  if (!RT)
+    return false;
+  const auto *RD = RT->getDecl();
+  if (!RD)
+    return false;
+
+  const IdentifierInfo *II = RD->getIdentifier();
+  if (!II)
+    return false;
+
+  if (II->getName() == "array") {
+    const NamespaceDecl *NS = dyn_cast<NamespaceDecl>(RD->getDeclContext());
----------------
EugeneZelenko wrote:

```suggestion
    const auto *NS = dyn_cast<NamespaceDecl>(RD->getDeclContext());
```

Type is spelled explicitly in same statement.

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

Reply via email to