Ericsson / clang

Cross Translation Unit analysis capability for Clang Static Analyzer. (Fork of official clang at http://llvm.org/git/clang)
http://clang.llvm.org/
Other
15 stars 10 forks source link

[clang7][Xerces] Assertion `DD && "queried property of class with no definition"' failed. #495

Closed martong closed 5 years ago

martong commented 6 years ago

Seems like a ClassTemplateSpecializationDecl created by the parser does not have definition. Perhaps during the import of an other TU we somehow overwrote the definition data.

(gdb) bt 20
#0  0x00007ffff10a2428 in __GI_raise (sig=sig@entry=6) at ../sysdeps/unix/sysv/linux/raise.c:54
#1  0x00007ffff10a402a in __GI_abort () at abort.c:89
#2  0x00007ffff109abd7 in __assert_fail_base (fmt=<optimized out>, assertion=assertion@entry=0x7fffea967e61 "DD && \"queried property of class with no definition\"", file=file@entry=0x7fffea967e96 "../../git/llvm/tools/clang/include/clang/AST/DeclCXX.h", line=line@entry=671, function=function@entry=0x7fffea967ecd "struct DefinitionData &clang::CXXRecordDecl::data() const") at assert.c:92
#3  0x00007ffff109ac82 in __GI___assert_fail (assertion=0x7fffea967e61 "DD && \"queried property of class with no definition\"", file=0x7fffea967e96 "../../git/llvm/tools/clang/include/clang/AST/DeclCXX.h", line=671, function=0x7fffea967ecd "struct DefinitionData &clang::CXXRecordDecl::data() const") at assert.c:101
#4  0x00007fffea7d6638 in clang::CXXRecordDecl::data (this=0x9d1fd0) at ../../git/llvm/tools/clang/include/clang/AST/DeclCXX.h:671
#5  0x00007fffea7d1295 in clang::CXXRecordDecl::hasMutableFields (this=0x9d1fd0) at ../../git/llvm/tools/clang/include/clang/AST/DeclCXX.h:1360
Python Exception <class 'gdb.error'> There is no member or method named EndX.:
#6  0x00007fffea7cc997 in clang::ento::CXXInstanceCall::getExtraInvalidatedValues (this=0xbdad60, Values=, ETraits=0x7fffffff4b38) at ../../git/llvm/tools/clang/lib/StaticAnalyzer/Core/CallEvent.cpp:608
#7  0x00007fffea7ca754 in clang::ento::CallEvent::invalidateRegions (this=0xbdad60, BlockCount=1, Orig=...) at ../../git/llvm/tools/clang/lib/StaticAnalyzer/Core/CallEvent.cpp:271
#8  0x00007fffea868785 in clang::ento::ExprEngine::conservativeEvalCall (this=0x7fffffff6d70, Call=..., Bldr=..., Pred=0x1f33620, State=...) at ../../git/llvm/tools/clang/lib/StaticAnalyzer/Core/ExprEngineCallAndReturn.cpp:602
#9  0x00007fffea8696d5 in clang::ento::ExprEngine::defaultEvalCall (this=0x7fffffff6d70, Bldr=..., Pred=0x1f33620, CallTemplate=..., CallOpts=...) at ../../git/llvm/tools/clang/lib/StaticAnalyzer/Core/ExprEngineCallAndReturn.cpp:987
#10 0x00007fffea7e911a in clang::ento::CheckerManager::runCheckersForEvalCall (this=0x4cfc80, Dst=..., Src=..., Call=..., Eng=...) at ../../git/llvm/tools/clang/lib/StaticAnalyzer/Core/CheckerManager.cpp:679
#11 0x00007fffea867f49 in clang::ento::ExprEngine::evalCall (this=0x7fffffff6d70, Dst=..., Pred=0x1f33620, Call=...) at ../../git/llvm/tools/clang/lib/StaticAnalyzer/Core/ExprEngineCallAndReturn.cpp:526
#12 0x00007fffea867e0c in clang::ento::ExprEngine::VisitCallExpr (this=0x7fffffff6d70, CE=0x22003d8, Pred=0x1f33620, dst=...) at ../../git/llvm/tools/clang/lib/StaticAnalyzer/Core/ExprEngineCallAndReturn.cpp:498
#13 0x00007fffea82c7f2 in clang::ento::ExprEngine::Visit (this=0x7fffffff6d70, S=0x22003d8, Pred=0x1f33620, DstTop=...) at ../../git/llvm/tools/clang/lib/StaticAnalyzer/Core/ExprEngine.cpp:1528
#14 0x00007fffea82931a in clang::ento::ExprEngine::ProcessStmt (this=0x7fffffff6d70, currStmt=0x22003d8, Pred=0x1f336c0) at ../../git/llvm/tools/clang/lib/StaticAnalyzer/Core/ExprEngine.cpp:732
#15 0x00007fffea828ff9 in clang::ento::ExprEngine::processCFGElement (this=0x7fffffff6d70, E=..., Pred=0x1f336c0, StmtIdx=4, Ctx=0x7fffffff6868) at ../../git/llvm/tools/clang/lib/StaticAnalyzer/Core/ExprEngine.cpp:570
#16 0x00007fffea80d126 in clang::ento::CoreEngine::HandlePostStmt (this=0x7fffffff6d90, B=0x21ef920, StmtIdx=4, Pred=0x1f336c0) at ../../git/llvm/tools/clang/lib/StaticAnalyzer/Core/CoreEngine.cpp:433
#17 0x00007fffea80ca51 in clang::ento::CoreEngine::dispatchWorkItem (this=0x7fffffff6d90, Pred=0x1f336c0, Loc=..., WU=...) at ../../git/llvm/tools/clang/lib/StaticAnalyzer/Core/CoreEngine.cpp:191
#18 0x00007fffea80c638 in clang::ento::CoreEngine::ExecuteWorkList (this=0x7fffffff6d90, L=0xace1c0, Steps=217819, InitState=...) at ../../git/llvm/tools/clang/lib/StaticAnalyzer/Core/CoreEngine.cpp:147
#19 0x00007fffeb6ac655 in clang::ento::ExprEngine::ExecuteWorkList (this=0x7fffffff6d70, L=0xace1c0, Steps=225000) at ../../git/llvm/tools/clang/include/clang/StaticAnalyzer/Core/PathSensitive/ExprEngine.h:168
(More stack frames follow...)
(gdb)