omtcyfz added inline comments.
================
Comment at: change-namespace/ChangeNamespace.cpp:30
@@ +29,3 @@
+ std::string Result = Namespaces.front();
+ for (auto I = Namespaces.begin() + 1, E = Namespaces.end(); I != E; ++I) {
+ Result += ("::" + *I).str();
----------------
Braces around single-line statement inside control flow statement body is
occasionally not welcome in LLVM Codebase.
There are actually both many braces around single-line statement inside cfs
body here and many cfs's without braces around single-line body inside a single
file, which isn't good in terms of consistency at least inside the project.
================
Comment at: change-namespace/ChangeNamespace.cpp:105
@@ +104,3 @@
+ llvm::StringRef File = SM.getBufferData(LocInfo.first, &InvalidTemp);
+ if (InvalidTemp)
+ return SourceLocation();
----------------
Shouldn't this throw an error instead?
https://reviews.llvm.org/D24183
_______________________________________________
cfe-commits mailing list
[email protected]
http://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits