- Nov 17, 2009
-
-
Zhongxing Xu authored
llvm-svn: 89060
-
- Nov 16, 2009
-
-
Douglas Gregor authored
sugared types. The basic problem is that our qualifier accessors (getQualifiers, getCVRQualifiers, isConstQualified, etc.) only look at the current QualType and not at any qualifiers that come from sugared types, meaning that we won't see these qualifiers through, e.g., typedefs: typedef const int CInt; typedef CInt Self; Self.isConstQualified() currently returns false! Various bugs (e.g., PR5383) have cropped up all over the front end due to such problems. I'm addressing this problem by splitting each qualifier accessor into two versions: - the "local" version only returns qualifiers on this particular QualType instance - the "normal" version that will eventually combine qualifiers from this QualType instance with the qualifiers on the canonical type to produce the full set of qualifiers. This commit adds the local versions and switches a few callers from the "normal" version (e.g., isConstQualified) over to the "local" version (e.g., isLocalConstQualified) when that is the right thing to do, e.g., because we're printing or serializing the qualifiers. Also, switch a bunch of Context.getCanonicalType(T1).getUnqualifiedType() == Context.getCanonicalType(T2).getQualifiedType() expressions over to Context.hasSameUnqualifiedType(T1, T2) llvm-svn: 88969
-
Zhongxing Xu authored
* Add a load type to GRExprEngine::EvalLoad(). * When retrieve from 'theValue' of OSAtomic funcitions, use the type of the region instead of the argument expression as the load type. * Then we can convert CastRetrievedSVal to a pure assertion. In the future we can let all Retrieve() methods simply return SVal. llvm-svn: 88888
-
Zhongxing Xu authored
llvm-svn: 88882
-
- Nov 14, 2009
-
-
Benjamin Kramer authored
- Eliminates many calls to std::string.c_str() - Fixes an invalid read in ReturnStackAddressChecker due to an unsafe call to StringRef.data() which doesn't guarantee null-termination. llvm-svn: 88779
-
Ted Kremenek authored
llvm-svn: 88729
-
- Nov 13, 2009
-
-
Ted Kremenek authored
option enables new "internal" checks that will eventually be turned on by default but still require broader testing. llvm-svn: 88671
-
Zhongxing Xu authored
llvm-svn: 87094
-
Zhongxing Xu authored
llvm-svn: 87093
-
Zhongxing Xu authored
llvm-svn: 87092
-
Zhongxing Xu authored
llvm-svn: 87091
-
Ted Kremenek authored
llvm-svn: 87065
-
Ted Kremenek authored
retain/release checker: refactor some of the summary lookup logic for instance method summaries. No real functionality change, but it paves the way for new enhancements. llvm-svn: 87062
-
Ted Kremenek authored
Add clang-cc option "-analyzer-experimental-checks" to enable experimental path-sensitive checks. The idea is to separate "barely working" or "skunkworks" checks from ones that should always run. Later we need more fine-grain checker control. llvm-svn: 87053
-
- Nov 12, 2009
-
-
Benjamin Kramer authored
llvm-svn: 86983
-
Zhongxing Xu authored
llvm-svn: 86979
-
Zhongxing Xu authored
llvm-svn: 86978
-
Ted Kremenek authored
PthreadLockChecker doesn't need PreVisitCallExpr() yet. All the current logic should be done in PostVisitCallExpr() llvm-svn: 86959
-
Ted Kremenek authored
Add most of the boilerplate logic for a simple pthread_mutux_lock() -> pthread_mutex_unlock() checker. We need to add a visitor method to Checker for handling dead symbols in order to detect locks that are not unlocked. llvm-svn: 86958
-
Ted Kremenek authored
llvm-svn: 86957
-
Ted Kremenek authored
Enhance Checker class (and GRExprEngine) to support PostVisitation for CallExprs. No clients (yet). llvm-svn: 86949
-
Ted Kremenek authored
llvm-svn: 86948
-
Zhongxing Xu authored
llvm-svn: 86932
-
- Nov 11, 2009
-
-
Ted Kremenek authored
Remove some stale ErrorNodes variables in GRExprEngine and the old buffer overflow logic in GRExprEngineInternalChecks.cpp. llvm-svn: 86877
-
Chandler Carruth authored
Sorry about that. llvm-svn: 86869
-
Chandler Carruth authored
llvm-svn: 86863
-
Zhongxing Xu authored
llvm-svn: 86837
-
Zhongxing Xu authored
llvm-svn: 86836
-
Zhongxing Xu authored
Now only one test case is XFAIL'ed. llvm-svn: 86834
-
Zhongxing Xu authored
explicitly. Fix 80-col violations. llvm-svn: 86833
-
Daniel Dunbar authored
llvm-svn: 86822
-
Ted Kremenek authored
CastToStructChecker: use 'isStructureType()' instead of 'isRecordType()' to determine if a pointer is casted to a struct pointer. This fixes an observed false positive when a value is casted to a union. llvm-svn: 86813
-
Ted Kremenek authored
Fix display of "ANALYZE" statements in AnalysisConsumer by correctly resetting the flag indicating that the current Decl* has not yet been displayed. Also move this out of AnalysisManager, since AnalysisManager should not handle text output to the user. llvm-svn: 86812
-
Ted Kremenek authored
Remove public headers for UndefinedArgChecker, AttrNonNullChecker, and BadCallChecker, making their implementations completely private. llvm-svn: 86809
-
Ted Kremenek authored
the old builder API. This percolated a bunch of changes up to the Checker class (where CheckLocation has been renamed VisitLocation) and GRExprEngine. ProgramPoint now has the notion of a "LocationCheck" point (with PreLoad and PreStore respectively), and a bunch of the old ProgramPoints that are no longer used have been removed. llvm-svn: 86798
-
- Nov 10, 2009
-
-
Zhongxing Xu authored
llvm-svn: 86677
-
Zhongxing Xu authored
This is reasonable because people know what they are doing when they intentionally dereference the pointer. So now we only emit warning when a pointer variable is use literally. llvm-svn: 86673
-
Zhongxing Xu authored
llvm-svn: 86663
-
Zhongxing Xu authored
llvm-svn: 86662
-
Zhongxing Xu authored
the argument is not an expression. llvm-svn: 86660
-