[clang-tools-extra] r209111 - Address review comments on r208954. No functional changes.
Sean Silva
chisophugis at gmail.com
Tue May 20 10:23:20 PDT 2014
Did you forget to add the helper function rename? They appear to still be
uppercase.
On Mon, May 19, 2014 at 1:23 AM, Daniel Jasper <djasper at google.com> wrote:
> Author: djasper
> Date: Mon May 19 02:23:03 2014
> New Revision: 209111
>
> URL: http://llvm.org/viewvc/llvm-project?rev=209111&view=rev
> Log:
> Address review comments on r208954. No functional changes.
>
> Modified:
> clang-tools-extra/trunk/clang-tidy/misc/UseOverride.cpp
>
> Modified: clang-tools-extra/trunk/clang-tidy/misc/UseOverride.cpp
> URL:
> http://llvm.org/viewvc/llvm-project/clang-tools-extra/trunk/clang-tidy/misc/UseOverride.cpp?rev=209111&r1=209110&r2=209111&view=diff
>
> ==============================================================================
> --- clang-tools-extra/trunk/clang-tidy/misc/UseOverride.cpp (original)
> +++ clang-tools-extra/trunk/clang-tidy/misc/UseOverride.cpp Mon May 19
> 02:23:03 2014
> @@ -88,9 +88,9 @@ void UseOverride::check(const MatchFinde
> StringRef ReplacementText = "override ";
>
> if (Method->hasAttrs()) {
> - for (const clang::Attr *attr : Method->getAttrs()) {
> - if (!attr->isImplicit()) {
> - InsertLoc = Sources.getExpansionLoc(attr->getLocation());
> + for (const clang::Attr *A : Method->getAttrs()) {
> + if (!A->isImplicit()) {
> + InsertLoc = Sources.getExpansionLoc(A->getLocation());
> break;
> }
> }
> @@ -117,11 +117,10 @@ void UseOverride::check(const MatchFinde
> }
>
> if (Method->isVirtualAsWritten()) {
> - for (unsigned i = 0, e = Tokens.size(); i != e; ++i) {
> - if (Tokens[i].is(tok::raw_identifier) &&
> - GetText(Tokens[i], Sources) == "virtual") {
> + for (Token Tok : Tokens) {
> + if (Tok.is(tok::raw_identifier) && GetText(Tok, Sources) ==
> "virtual") {
> Diag << FixItHint::CreateRemoval(CharSourceRange::getTokenRange(
> - Tokens[i].getLocation(), Tokens[i].getLocation()));
> + Tok.getLocation(), Tok.getLocation()));
> break;
> }
> }
>
>
> _______________________________________________
> cfe-commits mailing list
> cfe-commits at cs.uiuc.edu
> http://lists.cs.uiuc.edu/mailman/listinfo/cfe-commits
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.llvm.org/pipermail/cfe-commits/attachments/20140520/c50af5a2/attachment.html>
More information about the cfe-commits
mailing list