martong added inline comments.
================ Comment at: lib/AST/ASTImporter.cpp:2463 if (!ConflictingDecls.empty()) { - Name = Importer.HandleNameConflict(Name, DC, IDNS, + Name = Importer.HandleNameConflict(SearchName, DC, IDNS, ConflictingDecls.data(), ---------------- shafik wrote: > a_sidorin wrote: > > If I understand correctly, this will replace Name with SearchName causing > > an anonymous enum to be imported as a named a few lines below. It doesn't > > look like a correct behaviour to me. > This is correct because either `SearchName` is `Name` or it is the name of > the typedef for the anonymous enum set via `ImportInto(SearchName, > D->getTypedefNameForAnonDecl()->getDeclName())` Okay, this is indeed correct. But then we should make a similar change in VisitRecordDecl too (there we do exactly the same with typedefs). CHANGES SINCE LAST ACTION https://reviews.llvm.org/D59665/new/ https://reviews.llvm.org/D59665 _______________________________________________ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits