shafik added inline comments.

================
Comment at: clang/lib/AST/ASTImporter.cpp:2305-2309
+  BindingDecl *ToD;
+  if (GetImportedOrCreateDecl(ToD, D, Importer.getToContext(), DC, Loc,
+                              Name.getAsIdentifierInfo()))
+    return ToD;
+
----------------
martong wrote:
> So, we moved the import of the binding before importing the decomposition 
> decl to avoid an infinite recursion. But why can't we have an infinit 
> recursion this way?
> 
> Perhaps, it would be useful to have a test case that triggered the infinity 
> in case of the original order of the import calls.
Yes, I agree, I would also like to understand better why this avoids the 
infinite recursion problem, a test case would be helpful as well as an 
explanation of the steps that leads us to the problem.


Repository:
  rG LLVM Github Monorepo

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

https://reviews.llvm.org/D105354

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

Reply via email to