[PATCH] D23397: [clang-rename] cleanup `auto` usages
Kirill Bobyrev via cfe-commits
cfe-commits at lists.llvm.org
Mon Aug 15 16:21:28 PDT 2016
omtcyfz marked 2 inline comments as done.
================
Comment at: clang-rename/USRFinder.cpp:182-184
@@ -179,6 +181,5 @@
// We only want to search the decls that exist in the same file as the point.
- auto Decls = Context.getTranslationUnitDecl()->decls();
- for (auto &CurrDecl : Decls) {
- const auto FileLoc = CurrDecl->getLocStart();
- const auto FileName = Context.getSourceManager().getFilename(FileLoc);
+ for (const auto *CurrDecl : Context.getTranslationUnitDecl()->decls()) {
+ const SourceLocation FileLoc = CurrDecl->getLocStart();
+ StringRef FileName = Context.getSourceManager().getFilename(FileLoc);
// FIXME: Add test.
----------------
Aww, sure. Thanks!
https://reviews.llvm.org/D23397
More information about the cfe-commits
mailing list