]> granicus.if.org Git - clang/commit
[ASTImporter] Typedef import brings in the complete type
authorGabor Marton <martongabesz@gmail.com>
Tue, 27 Nov 2018 09:51:36 +0000 (09:51 +0000)
committerGabor Marton <martongabesz@gmail.com>
Tue, 27 Nov 2018 09:51:36 +0000 (09:51 +0000)
commit114aaa3c46f021df3c13f83d773589adc3993afd
treeeb79f4b199721d33c0152f65ff34550aa78f8e39
parent48602926c3083fe303bb6ffc2cacb55e79731c1f
[ASTImporter] Typedef import brings in the complete type

Summary:
When we already have an incomplete underlying type of a typedef in the
"To" context, and the "From" context has the same typedef, but the
underlying type is complete, then the imported type should be complete.

Fixes an assertion in CTU analysis of Xerces:
Assertion `DD && "queried property of class with no definition"' failed.
This assert is happening in the analyzer engine, because that attempts
to query an underlying type of a typedef, which happens to be
incomplete.

Reviewers: a_sidorin, a.sidorin

Subscribers: rnkovacs, dkrupp, Szelethus, cfe-commits

Differential Revision: https://reviews.llvm.org/D53693

git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@347648 91177308-0d34-0410-b5e6-96231b3b80d8
lib/AST/ASTImporter.cpp
unittests/AST/ASTImporterTest.cpp