jhen added a comment.
Thanks for the review!
Repository:
rL LLVM
https://reviews.llvm.org/D25450
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
http://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
This revision was automatically updated to reflect the committed changes.
jhen marked an inline comment as done.
Closed by commit rL284992: [clang-tidy] Fix identifier naming in macro args.
(authored by jhen).
Changed prior to commit:
https://reviews.llvm.org/D25450?vs=75430&id=75610#toc
Repos
aaron.ballman accepted this revision.
aaron.ballman added a comment.
This revision is now accepted and ready to land.
LGTM, thank you!
https://reviews.llvm.org/D25450
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
http://lists.llvm.org/cgi-
jhen marked an inline comment as done.
jhen added inline comments.
Comment at: clang-tidy/readability/IdentifierNamingCheck.cpp:654
+ RangeIsEntirelyWithinMacroArgument || !RangeContainsMacroExpansion;
+ Failure.ShouldFix = Failure.ShouldFix && RangeCanBeFixed;
}
-
jhen updated this revision to Diff 75430.
jhen added a comment.
- Early exit if not Failure.ShouldFix
https://reviews.llvm.org/D25450
Files:
clang-tidy/readability/IdentifierNamingCheck.cpp
test/clang-tidy/readability-identifier-naming.cpp
Index: test/clang-tidy/readability-identifier-nami
aaron.ballman added inline comments.
Comment at: clang-tidy/readability/IdentifierNamingCheck.cpp:654
+ RangeIsEntirelyWithinMacroArgument || !RangeContainsMacroExpansion;
+ Failure.ShouldFix = Failure.ShouldFix && RangeCanBeFixed;
}
We could do an early r
jhen added a comment.
Adding arron.ballman as a reviewer as alexfh seems to be on leave for a few
weeks.
https://reviews.llvm.org/D25450
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
http://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-comm
jhen added a comment.
I just found and fixed another bug in this patch. Before, I wasn't using the
spelling location for the fixit hint. This meant that a macro argument that was
expanded to two locations, for example, would have the same fixit hint applied
to it twice. My new test case verifie
jhen updated this revision to Diff 74184.
jhen added a comment.
- Prevent multiple fixes for macro expansion
https://reviews.llvm.org/D25450
Files:
clang-tidy/readability/IdentifierNamingCheck.cpp
test/clang-tidy/readability-identifier-naming.cpp
Index: test/clang-tidy/readability-identifi
jhen added a comment.
I found a bug in my first patch that I have fixed now. I was trying to iterate
over the source range by using `SourceLocation::getLocWithOffset`, but I
realized that doesn't work, so I removed it and went back to the original
method of checking `SourceRange.getBegin().isMa
jhen updated this revision to Diff 74181.
jhen added a comment.
- Return to original checking for macro in range
https://reviews.llvm.org/D25450
Files:
clang-tidy/readability/IdentifierNamingCheck.cpp
test/clang-tidy/readability-identifier-naming.cpp
Index: test/clang-tidy/readability-iden
jhen added a comment.
alexfh, sorry if you are not the right person to review this change. I based my
choice on this history of this file.
https://reviews.llvm.org/D25450
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
http://lists.llvm.org
jhen created this revision.
jhen added a reviewer: alexfh.
jhen added a subscriber: cfe-commits.
Herald added a subscriber: jlebar.
clang-tidy should fix identifier naming even when the identifier is
referenced inside a macro expansion, provided that the identifier enters
the macro expansion compl
13 matches
Mail list logo