[PATCH] D44804: [StaticAnalyzer] Silence an unused variable warning. NFC.
Mandeep Singh Grang via Phabricator via cfe-commits
cfe-commits at lists.llvm.org
Thu Mar 22 13:20:48 PDT 2018
mgrang updated this revision to Diff 139503.
mgrang added a comment.
Addressed comment.
Repository:
rC Clang
https://reviews.llvm.org/D44804
Files:
lib/StaticAnalyzer/Checkers/RetainCountChecker.cpp
Index: lib/StaticAnalyzer/Checkers/RetainCountChecker.cpp
===================================================================
--- lib/StaticAnalyzer/Checkers/RetainCountChecker.cpp
+++ lib/StaticAnalyzer/Checkers/RetainCountChecker.cpp
@@ -1931,7 +1931,7 @@
static Optional<std::string> describeRegion(const MemRegion *MR) {
if (const auto *VR = dyn_cast_or_null<VarRegion>(MR))
- return std::string(cast<VarRegion>(MR)->getDecl()->getName());
+ return std::string(VR->getDecl()->getName());
// Once we support more storage locations for bindings,
// this would need to be improved.
return None;
-------------- next part --------------
A non-text attachment was scrubbed...
Name: D44804.139503.patch
Type: text/x-patch
Size: 617 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/cfe-commits/attachments/20180322/6864f10b/attachment.bin>
More information about the cfe-commits
mailing list