- Oct 30, 2008
-
-
Zhongxing Xu authored
llvm-svn: 58419
-
Ted Kremenek authored
llvm-svn: 58410
-
- Oct 29, 2008
-
-
Zhongxing Xu authored
BindDecl better describes what the function does: - Bind the VarDecl to its memory region - Bind the memory region to some initial value. llvm-svn: 58359
-
- Oct 28, 2008
-
-
Douglas Gregor authored
llvm-svn: 58331
-
Douglas Gregor authored
- Do not allow expressions to ever have reference type - Extend Expr::isLvalue to handle more cases where having written a reference into the source implies that the expression is an lvalue (e.g., function calls, C++ casts). - Make GRExprEngine::VisitCall treat the call arguments as lvalues when they are being bound to a reference parameter. llvm-svn: 58306
-
Ted Kremenek authored
llvm-svn: 58292
-
- Oct 27, 2008
-
-
Ted Kremenek authored
- GRExprEngine::VisitCompoundLiteral... (1) visits the initializer list (generating ExplodedNodes) (2) creates a CompoundMemRegion for the literal (3) creates a new state with the bound literal values using GRStateManager::BindCompoundLiteral - GRStateManager::BindCompoundLiteral simply calls StoreManager::BindCompoundLiteral to get a new store and returns a persistent GRState with that store. - BasicStore::BindCompoundLiteral simply returns the same store, as it doesn't handle field sensitivity - RegionStore::BindCompoundLiteral currently fires an assert (pending discussion of how to best implement mappings for CompoundLiteralRegion). llvm-svn: 58277
-
Douglas Gregor authored
- CastExpr is the root of all casts - ImplicitCastExpr is (still) used for all explicit casts - ExplicitCastExpr is now the root of all *explicit* casts - ExplicitCCastExpr (new name needed!?) is a C-style cast in C or C++ - CXXFunctionalCastExpr inherits from ExplicitCastExpr - CXXNamedCastExpr inherits from ExplicitCastExpr and is the root of all of the C++ named cast expression types (static_cast, dynamic_cast, etc.) - Added classes CXXStaticCastExpr, CXXDynamicCastExpr, CXXReinterpretCastExpr, and CXXConstCastExpr to Also, fixed returned-stack-addr.cpp, which broke once when we fixed reinterpret_cast to diagnose double->int* conversions and again when we eliminated implicit conversions to reference types. The fix is in both testcase and SemaChecking.cpp. Most of this patch is simply support for the renaming. There's very little actual change in semantics. llvm-svn: 58264
-
- Oct 25, 2008
-
-
Ted Kremenek authored
This fixes PR 2948. llvm-svn: 58148
-
Zhongxing Xu authored
for StringLiteral lvalue evaluation, instead of directly returning a loc::StringLiteralVal by the Environment. llvm-svn: 58138
-
Zhongxing Xu authored
llvm-svn: 58135
-
- Oct 24, 2008
-
-
Ted Kremenek authored
Implicit conversions from arrays can also be conversions to references (will add a test case shortly). llvm-svn: 58110
-
Ted Kremenek authored
Added method "getSelfRegion" to Store. This method returns the region associated with the "this" or "self" object (C++ and Objective-C respectively). llvm-svn: 58107
-
Zhongxing Xu authored
llvm-svn: 58070
-
Ted Kremenek authored
llvm-svn: 58056
-
- Oct 23, 2008
-
-
Zhongxing Xu authored
llvm-svn: 58030
-
Zhongxing Xu authored
llvm-svn: 58028
-
- Oct 22, 2008
-
-
Zhongxing Xu authored
llvm-svn: 57964
-
Zhongxing Xu authored
llvm-svn: 57963
-
- Oct 21, 2008
-
-
Ted Kremenek authored
When conjuring symbols for compound assignments, use the promoted type to determine if the symbolic value as a "loc::" or "nonloc::" value. llvm-svn: 57917
-
Douglas Gregor authored
llvm-svn: 57909
-
Zhongxing Xu authored
GRExprEngine::VisitCast() so that other parts of the analyzer can be ignorant. When we cast "array of type T" to "pointer to T", we get the loc::MemRegionVal corresponding to the array variable. This is sufficient for BasicStore, but not for RegionStore. RegionStore should get the element region for the first array element in the cast. So next comes to the revamping of transfer functions for different store model. llvm-svn: 57897
-
Ted Kremenek authored
Further improve path-sensitivity with divide-by-zero checking by assuming that a denominator cannot be zero even when the result of an '/' or '%' expression is unknown. llvm-svn: 57855
-
Ted Kremenek authored
Used conjured symbols to recover path-sensitivity when the result of a compound assignment is UnknownVal(). llvm-svn: 57851
-
- Oct 19, 2008
-
-
Ted Kremenek authored
llvm-svn: 57777
-
- Oct 18, 2008
-
-
Ted Kremenek authored
Generalize VisitLValue: not only can CallExprs and ObjCMessageExprs return aggregate temporaries, so can many other expressions. llvm-svn: 57761
-
Ted Kremenek authored
Function calls and ObjC message expressions can be used in a lvalue context if they return a structure. E.g foo().x == 1. We don't really support, however, such temporaries yet in the environment or the store. llvm-svn: 57760
-
Ted Kremenek authored
Use "VisitLValue" when processing the base for "x.f" field accesses, and "Visit" when processing the base for "x->f" field accesses. llvm-svn: 57754
-
Ted Kremenek authored
When conjuring symbols to recover path-sensitivity, don't conjure symbols that represent an entire struct. We need to implement struct temporaries as an actual "region", and then bind symbols to the FieldRegion of those temporaries. llvm-svn: 57739
-
- Oct 17, 2008
-
-
Ted Kremenek authored
"Implement" GRExprEngine::VisitLValue for ObjCPropertyRefExpr. This is only a bandid; we need to properly handle properties by using locv/nonloc objects and specially handling property assignments in the transfer function for BinaryOperator. llvm-svn: 57693
-
Zhongxing Xu authored
RVal => SVal LVal => Loc NonLVal => NonLoc lval => loc nonlval => nonloc llvm-svn: 57671
-
Zhongxing Xu authored
llvm-svn: 57666
-
Zhongxing Xu authored
type T. llvm-svn: 57665
-
Ted Kremenek authored
llvm-svn: 57659
-
Ted Kremenek authored
Remove GRExprEngine::getLVal and RValues::MakeVal. Enhance StoreManager "GetLValue" methods to dispatch for specific kinds of lvalue queries, as opposed to interogating the expression tree (GRExprEngine already does this). Added FIXMEs. In particular, we no longer "assume" that a base pointer in a field/array access is null (this logic was removed). Perhaps we should do this when fetching the lvalue for fields and array elements? llvm-svn: 57657
-
Ted Kremenek authored
llvm-svn: 57654
-
- Oct 16, 2008
-
-
Zhongxing Xu authored
new VisitLValue method is added to replace the old VisitLVal. The semantics model becomes more explicit to separate rvalue evaluation from lvalue evaluation. llvm-svn: 57627
-
- Oct 09, 2008
-
-
Zhongxing Xu authored
llvm-svn: 57317
-
- Oct 07, 2008
-
-
Zhongxing Xu authored
llvm-svn: 57240
-
- Oct 06, 2008
-
-
Ted Kremenek authored
Don't use DeclStmt::getDecl(); this will eventually disappear. Just fetch the first decl using the DeclStmt::decl_iterator. llvm-svn: 57194
-