aboutsummaryrefslogtreecommitdiff
path: root/lib/StaticAnalyzer/Checkers/CheckObjCDealloc.cpp
diff options
context:
space:
mode:
authorBenjamin Kramer <benny.kra@googlemail.com>2011-10-14 18:45:37 +0000
committerBenjamin Kramer <benny.kra@googlemail.com>2011-10-14 18:45:37 +0000
commitb8989f27f116ff2400e92a52c067a69846119eb5 (patch)
treefad64c15a367b5059588e3d6d3a70e08044048ac /lib/StaticAnalyzer/Checkers/CheckObjCDealloc.cpp
parent2b5cfbc0b074ef77ccac407533d27778ace4028c (diff)
Change operator<< for raw_ostream and NamedDecl to take a reference instead of a pointer.
Passing a pointer was a bad idea as it collides with the overload for void*. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@141971 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'lib/StaticAnalyzer/Checkers/CheckObjCDealloc.cpp')
-rw-r--r--lib/StaticAnalyzer/Checkers/CheckObjCDealloc.cpp6
1 files changed, 3 insertions, 3 deletions
diff --git a/lib/StaticAnalyzer/Checkers/CheckObjCDealloc.cpp b/lib/StaticAnalyzer/Checkers/CheckObjCDealloc.cpp
index de9c021398..c325bb1517 100644
--- a/lib/StaticAnalyzer/Checkers/CheckObjCDealloc.cpp
+++ b/lib/StaticAnalyzer/Checkers/CheckObjCDealloc.cpp
@@ -230,7 +230,7 @@ static void checkObjCDealloc(const ObjCImplementationDecl *D,
// ivars cannot be set via read-only properties, so we'll skip them
if (PD->isReadOnly())
- continue;
+ continue;
// ivar must be released if and only if the kind of setter was not 'assign'
bool requiresRelease = PD->getSetterKind() != ObjCPropertyDecl::Assign;
@@ -247,7 +247,7 @@ static void checkObjCDealloc(const ObjCImplementationDecl *D,
? "missing ivar release (leak)"
: "missing ivar release (Hybrid MM, non-GC)";
- os << "The '" << ID
+ os << "The '" << *ID
<< "' instance variable was retained by a synthesized property but "
"wasn't released in 'dealloc'";
} else {
@@ -255,7 +255,7 @@ static void checkObjCDealloc(const ObjCImplementationDecl *D,
? "extra ivar release (use-after-release)"
: "extra ivar release (Hybrid MM, non-GC)";
- os << "The '" << ID
+ os << "The '" << *ID
<< "' instance variable was not retained by a synthesized property "
"but was released in 'dealloc'";
}