Remove an untrue assertion: lval::FuncVals can be returned in both rvalue and lvalue contexts.

llvm-svn: 57659
This commit is contained in:
Ted Kremenek 2008-10-17 00:55:33 +00:00
parent 7ff153c9cb
commit 357c63ab37
1 changed files with 4 additions and 2 deletions

View File

@ -834,8 +834,10 @@ void GRExprEngine::VisitDeclRefExpr(DeclRefExpr* Ex, NodeTy* Pred, NodeSet& Dst,
return;
} else if (const FunctionDecl* FD = dyn_cast<FunctionDecl>(D)) {
assert(!asLValue && "FunctionDecl does not have lvalue.");
// We return the lval::FuncVal for an FunctionDecl in both rvalue
// and lvalue contexts.
// FIXME: Does this need to be revised? We were getting cases in
// real code that did this.
RVal V = lval::FuncVal(FD);
MakeNode(Dst, Ex, Pred, SetRVal(St, Ex, V));
return;