================
@@ -5172,8 +5179,28 @@ QualType::DestructionKind 
QualType::isDestructedTypeImpl(QualType type) {
   return DK_none;
 }
 
+bool MemberPointerType::isSugared() const {
+  CXXRecordDecl *D1 = getMostRecentCXXRecordDecl(),
+                *D2 = getQualifier()->getAsRecordDecl();
+  return D1 != D2 && D1->getCanonicalDecl() != D2->getCanonicalDecl();
----------------
erichkeane wrote:

A `assert((D1 == nullptr) == (D2 == nullptr));` is valid here, I can already 
see every static analysis tool recoiling in horror in this function :) 

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

Reply via email to