hokein added inline comments.

================
Comment at: clang-rename/USRLocFinder.cpp:157
+    clang::NestedNameSpecifierLoc nested_name_specifier =
+        TL.castAs<clang::ElaboratedTypeLoc>().getQualifierLoc();
+    if (nested_name_specifier.getNestedNameSpecifier())
----------------
ioeric wrote:
> Is this cast always safe? 
Yes, because we have checked the type of the TL is an elaborated type. I have 
changed to `getAs` which makes the indication more explicitly.


================
Comment at: clang-rename/USRLocFinder.cpp:196
+
+class RenameLocFindingASTVisitor
+    : public clang::RecursiveASTVisitor<RenameLocFindingASTVisitor> {
----------------
ioeric wrote:
> ioeric wrote:
> > Comments.
> I think this visitor deserves a file of its own.
I'm not sure it is the right time to do it at the moment since it is in early 
stage. I'd keep it here. We can do it when needed. 


================
Comment at: clang-rename/USRLocFinder.cpp:368
+private:
+  bool IsTypeAliasWhichWillBeRenamedElsewhere(TypeLoc TL) const {
+    while (!TL.isNull()) {
----------------
ioeric wrote:
> Note this is not expected behavior for alias types which would always be 
> skipped in this check.
Acked. Add a FIXME.


https://reviews.llvm.org/D31176



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

Reply via email to