hokein marked an inline comment as done.
hokein added inline comments.

================
Comment at: clang/include/clang/AST/RecursiveASTVisitor.h:1169
 DEF_TRAVERSE_TYPELOC(MemberPointerType, {
-  TRY_TO(TraverseType(QualType(TL.getTypePtr()->getClass(), 0)));
+  if (auto *TSI = TL.getClassTInfo())
+    TRY_TO(TraverseTypeLoc(TSI->getTypeLoc()));
----------------
saugustine wrote:
> ilya-biryukov wrote:
> > Can this actually happen in practice?
> > Did we try doing **only** `TRY_TO(TraverseTypeLoc(TSI->getTypeLoc()))` and 
> > seeing whether this fails?
> > 
> > The code in `MemberPointerTypeLoc` suggests this can happen, but would be 
> > interesting to find examples when it happens.
> This can happen when traversing a TypeNodeLoc, and the assertion will fail. 
> I'm reverting this change for now.
> This can happen when traversing a TypeNodeLoc, and the assertion will fail. 
> I'm reverting this change for now.

Thanks for reverting it, could you share more details?  would be nice if you 
could point us an example that triggers the assertion, I believe it was found 
when you did the llvm buildcop.


Repository:
  rG LLVM Github Monorepo

CHANGES SINCE LAST ACTION
  https://reviews.llvm.org/D70849/new/

https://reviews.llvm.org/D70849



_______________________________________________
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

Reply via email to