[PATCH] D63603: [ASTImporter] Propagate error from ImportDeclContext

Gabor Marton via Phabricator via cfe-commits cfe-commits at lists.llvm.org
Thu Jun 20 07:41:19 PDT 2019


martong created this revision.
martong added a reviewer: a_sidorin.
Herald added subscribers: cfe-commits, gamesh411, Szelethus, dkrupp, rnkovacs.
Herald added a reviewer: a.sidorin.
Herald added a reviewer: shafik.
Herald added a project: clang.
martong added a parent revision: D62373: [ASTImporter] Store import errors for Decls.
martong added a child revision: D62375: [ASTImporter] Mark erroneous nodes in from ctx.

During analysis of one project we failed to import one
CXXDestructorDecl. But since we did not propagate the error in
importDeclContext we had a CXXRecordDecl without a destructor. Then the
analyzer engine had a CallEvent where the nonexistent dtor was requested
(crash).

Solution is to propagate the errors we have during importing a
DeclContext.


Repository:
  rG LLVM Github Monorepo

https://reviews.llvm.org/D63603

Files:
  clang/lib/AST/ASTImporter.cpp
  clang/unittests/AST/ASTImporterTest.cpp

-------------- next part --------------
A non-text attachment was scrubbed...
Name: D63603.205810.patch
Type: text/x-patch
Size: 4703 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/cfe-commits/attachments/20190620/f45d0f35/attachment-0001.bin>


More information about the cfe-commits mailing list