History log of /llvm-project/clang/lib/StaticAnalyzer/Checkers/ObjCSelfInitChecker.cpp (Results 26 – 50 of 68)
Revision (<<< Hide revision tags) (Show revision tags >>>) Date Author Comments
# cfe5aedd 01-Dec-2012 Benjamin Kramer <benny.kra@googlemail.com>

Add raw_ostream include to pacify MSVC.

llvm-svn: 169097


Revision tags: llvmorg-3.2.0-rc2, llvmorg-3.2.0-rc1
# 829c3831 02-Nov-2012 Jordan Rose <jordan_rose@apple.com>

[analyzer] Add some convenience accessors to CallEvent, and use them.

These are CallEvent-equivalents of helpers already accessible in
CheckerContext, as part of making it easier for new checkers to

[analyzer] Add some convenience accessors to CallEvent, and use them.

These are CallEvent-equivalents of helpers already accessible in
CheckerContext, as part of making it easier for new checkers to be written
using CallEvent rather than raw CallExprs.

llvm-svn: 167338

show more ...


# b9ed61f9 02-Nov-2012 Jordan Rose <jordan_rose@apple.com>

[analyzer] Convert some of the harder cases over to ProgramStateTrait macros.

Add FIXMEs for the traits visible from multiple translation units.
Currently the macros hide their key types in an anony

[analyzer] Convert some of the harder cases over to ProgramStateTrait macros.

Add FIXMEs for the traits visible from multiple translation units.
Currently the macros hide their key types in an anonymous namespace.

llvm-svn: 167277

show more ...


# e10d5a76 02-Nov-2012 Jordan Rose <jordan_rose@apple.com>

[analyzer] Rename 'EmitReport' to 'emitReport'.

No functionality change.

llvm-svn: 167275


# 5481cfef 08-Sep-2012 Jordan Rose <jordan_rose@apple.com>

[analyzer] ObjCSelfInitChecker should always clean up in postCall checks.

ObjCSelfInitChecker stashes information in the GDM to persist it across
function calls; it is stored in pre-call checks and

[analyzer] ObjCSelfInitChecker should always clean up in postCall checks.

ObjCSelfInitChecker stashes information in the GDM to persist it across
function calls; it is stored in pre-call checks and retrieved post-call.
The post-call check is supposed to clear out the stored state, but was
failing to do so in cases where the call did not have a symbolic return
value.

This was actually causing the inappropriate cache-out from r163361.
Per discussion with Anna, we should never actually cache out when
assuming the receiver of an Objective-C message is non-nil, because
we guarded that node generation by checking that the state has changed.
Therefore, the only states that could reach this exact ExplodedNode are
ones that should have merged /before/ making this assumption.

r163361 has been reverted and the test case removed, since it won't
actually test anything interesting now.

llvm-svn: 163449

show more ...


# bd94e5d8 08-Sep-2012 Jordan Rose <jordan_rose@apple.com>

[analyzer] Add debug output for ObjCSelfInitChecker's state.

No functionality change.

llvm-svn: 163448


# 4f7df9be 26-Jul-2012 Jordan Rose <jordan_rose@apple.com>

[analyzer] Rename Calls.{h,cpp} to CallEvent.{h,cpp}. No functionality change.

llvm-svn: 160815


# 682b3162 02-Jul-2012 Jordan Rose <jordan_rose@apple.com>

[analyzer] Convert existing checkers to use check::preCall and check::postCall.

llvm-svn: 159563


# 547060b3 02-Jul-2012 Jordan Rose <jordan_rose@apple.com>

[analyzer] Finish replacing ObjCMessage with ObjCMethodDecl and friends.

The preObjCMessage and postObjCMessage callbacks now take an ObjCMethodCall
argument, which can represent an explicit message

[analyzer] Finish replacing ObjCMessage with ObjCMethodDecl and friends.

The preObjCMessage and postObjCMessage callbacks now take an ObjCMethodCall
argument, which can represent an explicit message send (ObjCMessageSend) or an
implicit message generated by a property access (ObjCPropertyAccess).

llvm-svn: 159559

show more ...


# 6bad4905 02-Jul-2012 Jordan Rose <jordan_rose@apple.com>

[analyzer] Begin replacing ObjCMessage with ObjCMethodCall and friends.

Previously, the CallEvent subclass ObjCMessageInvocation was just a wrapper
around the existing ObjCMessage abstraction (over

[analyzer] Begin replacing ObjCMessage with ObjCMethodCall and friends.

Previously, the CallEvent subclass ObjCMessageInvocation was just a wrapper
around the existing ObjCMessage abstraction (over message sends and property
accesses). Now, we have abstract CallEvent ObjCMethodCall with subclasses
ObjCMessageSend and ObjCPropertyAccess.

In addition to removing yet another wrapper object, this should make it easy
to add a ObjCSubscriptAccess call event soon.

llvm-svn: 159558

show more ...


# 2995349f 02-Jul-2012 Jordan Rose <jordan_rose@apple.com>

[analyzer] Convert CallAndMessageChecker and ObjCSelfInitChecker to CallEvent.

Both of these got uglier rather than cleaner because we don't have preCall and
postCall yet; properly wrapping a CallEx

[analyzer] Convert CallAndMessageChecker and ObjCSelfInitChecker to CallEvent.

Both of these got uglier rather than cleaner because we don't have preCall and
postCall yet; properly wrapping a CallExpr in a CallEvent requires doing a bit
of deconstruction on the callee. Even when we have preCall and postCall we may
want to expose the current CallEvent to pre/postStmt<CallExpr>.

llvm-svn: 159556

show more ...


Revision tags: llvmorg-3.1.0
# 66843480 08-May-2012 Anna Zaks <ganna@apple.com>

[analyzer] SelfInit: Stop tracking self if it's assigned a value we
don't reason about.

Self is just like a local variable in init methods, so it can be
assigned anything like result of static funct

[analyzer] SelfInit: Stop tracking self if it's assigned a value we
don't reason about.

Self is just like a local variable in init methods, so it can be
assigned anything like result of static functions, other methods ... So
to suppress false positives that result in such cases, stop tracking the
checker-specific state after self is being assigned to (unless the
value is't being assigned to is either self or conforms to our rules).

This change does not invalidate any existing regression tests.

llvm-svn: 156420

show more ...


Revision tags: llvmorg-3.1.0-rc3, llvmorg-3.1.0-rc2, llvmorg-3.1.0-rc1
# 51244c22 16-Apr-2012 Anna Zaks <ganna@apple.com>

[analyzer] Fix a false alarm in SelfInitChecker (radar://11235991).
Along with it, fix a couple of other corner cases and add more tests.

llvm-svn: 154866


# b45d198b 05-Apr-2012 Ted Kremenek <kremenek@apple.com>

Require that all static analyzer issues have a category. As part of this change,
consolidate some commonly used category strings into global references (more of this can be done, I just did a few).

Require that all static analyzer issues have a category. As part of this change,
consolidate some commonly used category strings into global references (more of this can be done, I just did a few).

Fixes <rdar://problem/11191537>.

llvm-svn: 154121

show more ...


# 53a0b6c1 05-Mar-2012 Anna Zaks <ganna@apple.com>

[analyzer] False positive in SelfInit - teach the checker about method
calls with self as a parameter.

llvm-svn: 152039


# e98d63a8 18-Feb-2012 Ted Kremenek <kremenek@apple.com>

Adopt ExprEngine and checkers to ObjC property refactoring. Everything was working, but now diagnostics are aware of message expressions implied by uses of properties. Fixes <rdar://problem/9241180

Adopt ExprEngine and checkers to ObjC property refactoring. Everything was working, but now diagnostics are aware of message expressions implied by uses of properties. Fixes <rdar://problem/9241180>.

llvm-svn: 150888

show more ...


# 00790d9a 04-Feb-2012 Anna Zaks <ganna@apple.com>

[analyzer] Minor cleanups to the ObjCSelfInitChecker.
(Also renames in other ObjC checkers to create one category of checks.)

llvm-svn: 149745


# 49b1e38e 26-Jan-2012 Ted Kremenek <kremenek@apple.com>

Change references to 'const ProgramState *' to typedef 'ProgramStateRef'.

At this point this is largely cosmetic, but it opens the door to replace
ProgramStateRef with a smart pointer that more eage

Change references to 'const ProgramState *' to typedef 'ProgramStateRef'.

At this point this is largely cosmetic, but it opens the door to replace
ProgramStateRef with a smart pointer that more eagerly acts in the role
of reclaiming unused ProgramState objects.

llvm-svn: 149081

show more ...


# 632e3b7e 06-Jan-2012 Ted Kremenek <kremenek@apple.com>

[analyzer] Make the entries in 'Environment' context-sensitive by making entries map from
(Stmt*,LocationContext*) pairs to SVals instead of Stmt* to SVals.

This is needed to support basic IPA via i

[analyzer] Make the entries in 'Environment' context-sensitive by making entries map from
(Stmt*,LocationContext*) pairs to SVals instead of Stmt* to SVals.

This is needed to support basic IPA via inlining. Without this, we cannot tell
if a Stmt* binding is part of the current analysis scope (StackFrameContext) or
part of a parent context.

This change introduces an uglification of the use of getSVal(), and thus takes
two steps forward and one step back. There are also potential performance implications
of enlarging the Environment. Both can be addressed going forward by refactoring the
APIs and optimizing the internal representation of Environment. This patch
mainly introduces the functionality upon when we want to build upon (and clean up).

llvm-svn: 147688

show more ...


Revision tags: llvmorg-3.0.0, llvmorg-3.0.0-rc4, llvmorg-3.0.0-rc3, llvmorg-3.0.0-rc2
# da4c8d68 26-Oct-2011 Anna Zaks <ganna@apple.com>

[analyzer] Rename generateNode -> addTransition in CheckerContext

Also document addTransition methods.

llvm-svn: 143059


# b473816b 25-Oct-2011 Anna Zaks <ganna@apple.com>

[analyzer] Simplify CheckerContext

Remove dead members/parameters: ProgramState, respondsToCallback, autoTransition.
Remove addTransition method since it's the same as generateNode. Maybe we should

[analyzer] Simplify CheckerContext

Remove dead members/parameters: ProgramState, respondsToCallback, autoTransition.
Remove addTransition method since it's the same as generateNode. Maybe we should
rename generateNode to genTransition (since a transition is always automatically
generated)?

llvm-svn: 142946

show more ...


# 81ce1c8a 24-Oct-2011 Ted Kremenek <kremenek@apple.com>

Rename AnalysisContext to AnalysisDeclContext. Not only is this name more accurate, but it frees up the name AnalysisContext for other uses.

llvm-svn: 142782


Revision tags: llvmorg-3.0.0-rc1
# 3e0f415d 06-Oct-2011 Anna Zaks <ganna@apple.com>

[analyzer] Remove the dependency on CheckerContext::getStmt() as well as the method itself.

llvm-svn: 141262


# 087611ed 02-Sep-2011 Jordy Rose <jediknil@belkadan.com>

[analyzer] Remove TransferFuncs.h, then deal with the fallout.

And with that, TransferFuncs is gone!

llvm-svn: 139003


# 3a6bdf8f 17-Aug-2011 Anna Zaks <ganna@apple.com>

Remove EnhancedBugReport and RangedBugReport - pull all the extra functionality they provided into their parent BugReport. The only functional changes are: made getRanges() non const - it adds defaul

Remove EnhancedBugReport and RangedBugReport - pull all the extra functionality they provided into their parent BugReport. The only functional changes are: made getRanges() non const - it adds default range to Ranges if none are supplied, made getStmt() private, which was another FIXME.

llvm-svn: 137894

show more ...


123