klimek accepted this revision.
klimek added a comment.
This revision is now accepted and ready to land.

lg


================
Comment at: clang-rename/USRLocFinder.cpp:126-128
@@ -118,3 +125,5 @@
   // All the locations of the USR were found.
-  const std::string USR;
+  StringRef USR;
+  // Old name that is renamed.
+  StringRef PrevName;
   std::vector<clang::SourceLocation> LocationsFound;
----------------
Usually storing StringRefs in the class is dangerous, but as this is defined in 
the .cpp file and only used as part of the function, that's probably fine.
(I personally would still make them std::string members, and copy either in the 
constructor or when passing into the function).


http://reviews.llvm.org/D20216



_______________________________________________
cfe-commits mailing list
cfe-commits@lists.llvm.org
http://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

Reply via email to