[analyzer] fix inlining's handling of mapping actual to formal arguments and limit the call stack depth. The analyzer can now accurately simulate factorial for limited depths.

llvm-svn: 148036
This commit is contained in:
Ted Kremenek
2012-01-12 19:25:46 +00:00
parent 9eae723c18
commit 3d3aea9374
7 changed files with 76 additions and 19 deletions

View File

@@ -180,9 +180,11 @@ const ProgramState *ProgramState::unbindLoc(Loc LV) const {
return makeWithStore(newStore);
}
const ProgramState *ProgramState::enterStackFrame(const StackFrameContext *frame) const {
const ProgramState *
ProgramState::enterStackFrame(const LocationContext *callerCtx,
const StackFrameContext *calleeCtx) const {
const StoreRef &new_store =
getStateManager().StoreMgr->enterStackFrame(this, frame);
getStateManager().StoreMgr->enterStackFrame(this, callerCtx, calleeCtx);
return makeWithStore(new_store);
}