diff options
author | Anna Zaks <ganna@apple.com> | 2012-09-17 19:13:56 +0000 |
---|---|---|
committer | Anna Zaks <ganna@apple.com> | 2012-09-17 19:13:56 +0000 |
commit | 42782343606a4c50fb5f237bbda37823b67e845b (patch) | |
tree | 8c674eafdda407b09d67e0893b3ada974057113f /clang/lib/StaticAnalyzer/Checkers/MallocChecker.cpp | |
parent | 4f0e00a5b8c2f2c9792cea1d7e8a4b5bcc1cc237 (diff) | |
download | bcm5719-llvm-42782343606a4c50fb5f237bbda37823b67e845b.tar.gz bcm5719-llvm-42782343606a4c50fb5f237bbda37823b67e845b.zip |
[analyzer] Teach the analyzer about implicit initialization of statics
in ObjCMethods.
Extend FunctionTextRegion to represent ObjC methods as well as
functions. Note, it is not clear what type ObjCMethod region should
return. Since the type of the FunctionText region is not currently used,
defer solving this issue.
llvm-svn: 164046
Diffstat (limited to 'clang/lib/StaticAnalyzer/Checkers/MallocChecker.cpp')
-rw-r--r-- | clang/lib/StaticAnalyzer/Checkers/MallocChecker.cpp | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/clang/lib/StaticAnalyzer/Checkers/MallocChecker.cpp b/clang/lib/StaticAnalyzer/Checkers/MallocChecker.cpp index f57ea12ee07..c036d739dd4 100644 --- a/clang/lib/StaticAnalyzer/Checkers/MallocChecker.cpp +++ b/clang/lib/StaticAnalyzer/Checkers/MallocChecker.cpp @@ -739,7 +739,7 @@ bool MallocChecker::SummarizeRegion(raw_ostream &os, const MemRegion *MR) { switch (MR->getKind()) { case MemRegion::FunctionTextRegionKind: { - const FunctionDecl *FD = cast<FunctionTextRegion>(MR)->getDecl(); + const NamedDecl *FD = cast<FunctionTextRegion>(MR)->getDecl(); if (FD) os << "the address of the function '" << *FD << '\''; else |