martong added inline comments.
================ Comment at: lib/AST/ASTImporter.cpp:4966 // it has any definition in the redecl chain. -static ClassTemplateDecl *getDefinition(ClassTemplateDecl *D) { - CXXRecordDecl *ToTemplatedDef = D->getTemplatedDecl()->getDefinition(); +template <typename T> static auto getDefinition(T *D) -> T * { + auto *ToTemplatedDef = D->getTemplatedDecl()->getDefinition(); ---------------- a_sidorin wrote: > We should point that this function is for TemplateDecls only somehow. But we > can't just pass TemplateDecl as the parameter due to loss of the actual > return type. Maybewe should rename this function into > "getTemplateDefinition()"? Ok, I changed that to `getTemplateDefinition`. ================ Comment at: lib/AST/ASTImporter.cpp:5563 + // TODO: handle conflicting names + } // linkage + } // template ---------------- a_sidorin wrote: > We don't usually put such comments after control flow statements. If they are > really needed, it is a good sign that a function must be split, and it's > better to leave a FIXME for this (or do the split). Ok, I removed these comments and added a FIXME. Repository: rC Clang CHANGES SINCE LAST ACTION https://reviews.llvm.org/D58494/new/ https://reviews.llvm.org/D58494 _______________________________________________ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits