From 557c8a817a53a540a03ed118ddf6d9a9cd8d6c0c Mon Sep 17 00:00:00 2001 From: George Burgess IV Date: Thu, 10 Nov 2016 21:47:12 +0000 Subject: [PATCH] [Sema] Range-ify for loop, add period to comment. NFC. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@286506 91177308-0d34-0410-b5e6-96231b3b80d8 --- lib/Sema/SemaDeclAttr.cpp | 4 ++-- lib/Sema/SemaOverload.cpp | 2 +- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/lib/Sema/SemaDeclAttr.cpp b/lib/Sema/SemaDeclAttr.cpp index 1be69c5276..ffb1051bb4 100644 --- a/lib/Sema/SemaDeclAttr.cpp +++ b/lib/Sema/SemaDeclAttr.cpp @@ -825,8 +825,8 @@ static void handleEnableIfAttr(Sema &S, Decl *D, const AttributeList &Attr) { !Expr::isPotentialConstantExprUnevaluated(Cond, cast(D), Diags)) { S.Diag(Attr.getLoc(), diag::err_enable_if_never_constant_expr); - for (int I = 0, N = Diags.size(); I != N; ++I) - S.Diag(Diags[I].first, Diags[I].second); + for (const PartialDiagnosticAt &PDiag : Diags) + S.Diag(PDiag.first, PDiag.second); return; } diff --git a/lib/Sema/SemaOverload.cpp b/lib/Sema/SemaOverload.cpp index cdfb30b30a..2e56786326 100644 --- a/lib/Sema/SemaOverload.cpp +++ b/lib/Sema/SemaOverload.cpp @@ -12498,7 +12498,7 @@ Sema::BuildCallToMemberFunction(Scope *S, Expr *MemExprE, // In the case the method to call was not selected by the overloading // resolution process, we still need to handle the enable_if attribute. Do - // that here, so it will not hide previous -- and more relevant -- errors + // that here, so it will not hide previous -- and more relevant -- errors. if (isa(NakedMemExpr)) { if (const EnableIfAttr *Attr = CheckEnableIf(Method, Args, true)) { Diag(MemExprE->getLocStart(), -- 2.40.0