Hm, you're right in theory...but in practice, the original `Dest` region 
could be null with the new temporary stuff Pavel's been working on, and 
possibly even with a base or member destructor where the top-level region is 
Unknown. We really should check for this case and create UnknownVal instead of 
just automatically wrapping in loc::MemRegionVal.

  And oops, I meant Unknown-handling, not null-handling...i.e. a case where we 
know which destructor to call because of the delete-expr's type, but not which 
region to act on. That's what the reinterpret_cast is for – to push beyond what 
the analyzer can currently model.

  ProgramState::isNull and ProgramState::assume should not crash, but maybe 
it's the loc::MemRegionVal wrapped around a null region. We should figure out 
what's going on there before moving forward.

http://llvm-reviews.chandlerc.com/D1594
_______________________________________________
cfe-commits mailing list
[email protected]
http://lists.cs.uiuc.edu/mailman/listinfo/cfe-commits

Reply via email to