================
@@ -5558,6 +5558,38 @@ QualType::DestructionKind 
QualType::isDestructedTypeImpl(QualType type) {
   return DK_none;
 }
 
+static bool
+requiresBuiltinLaunderImpl(const ASTContext &Context, QualType Ty,
+                           llvm::SmallPtrSetImpl<const Decl *> &Seen) {
+  if (const auto *Arr = Context.getAsArrayType(Ty))
+    Ty = Context.getBaseElementType(Arr);
+
+  const auto *Record = Ty->getAsCXXRecordDecl();
+  if (!Record)
+    return false;
+
+  // We've already checked this type, or are in the process of checking it.
+  if (!Seen.insert(Record).second)
+    return false;
+
+  assert(Record->hasDefinition() &&
+         "Incomplete types should already be diagnosed");
+
+  if (Record->isDynamicClass())
+    return true;
+
+  for (FieldDecl *F : Record->fields()) {
----------------
erichkeane wrote:

Seemingly no.  Best I can tell is the `isDynamicClass` test considers dynamic 
bases as well: 
https://godbolt.org/z/6rTdaqr66

https://github.com/llvm/llvm-project/pull/197252
_______________________________________________
cfe-commits mailing list
[email protected]
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

Reply via email to