martong marked an inline comment as done. martong added inline comments.
================ Comment at: lib/CrossTU/CrossTranslationUnit.cpp:147 llvm::Expected<const FunctionDecl *> CrossTranslationUnitContext::getCrossTUDefinition(const FunctionDecl *FD, ---------------- balazske wrote: > Szelethus wrote: > > Would it be worth to add a comment that this function never returns with > > `nullptr` on success? > Even on failure not. Failure should be `Error`, success is a non-null pointer. Yes, you are right. We should indicate that in the documentation of this function that it can not return with a nullptr on success. I think we should do that in here https://reviews.llvm.org/D55131 because there we do check that the `ToDecl` is not a nullptr. Repository: rC Clang CHANGES SINCE LAST ACTION https://reviews.llvm.org/D55280/new/ https://reviews.llvm.org/D55280 _______________________________________________ cfe-commits mailing list cfe-commits@lists.llvm.org http://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits