Fixed assertion in Deserializer::~Deserializer that checks for

pointers that were not backpatched (previously checked the wrong invariant).


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@43425 91177308-0d34-0410-b5e6-96231b3b80d8
This commit is contained in:
Ted Kremenek 2007-10-28 23:38:38 +00:00
parent 536c64b4d6
commit adc9b9c317

View File

@ -22,8 +22,12 @@ Deserializer::Deserializer(BitstreamReader& stream)
Deserializer::~Deserializer() {
assert (RecIdx >= Record.size() &&
"Still scanning bitcode record when deserialization completed.");
assert (FreeList == NULL && "Some pointers were not backpatched.");
#ifdef NDEBUG
for (MapTy::iterator I=BPatchMap.begin(), E=BPatchMap.end(); I!=E; ++I)
assert (I->second.hasFinalPtr() &&
"Some pointers were not backpatched.");
#endif
}