diff options
author | Noel Grandin <noel@peralex.com> | 2015-05-28 15:44:10 +0200 |
---|---|---|
committer | Noel Grandin <noel@peralex.com> | 2015-05-29 08:48:41 +0200 |
commit | 6140ca9f1d728475e332f9fa96ee62dda58687ea (patch) | |
tree | 284733762d73048939675ca39a8932a3ca2009f5 /compilerplugins | |
parent | afcf1ecee1af1312551583b9fc860c1881ba2134 (diff) |
loplugin:loopvartoosmall
Change-Id: Icb31e51575f7fffd36be73bbd87a3c5e56c3aa26
Diffstat (limited to 'compilerplugins')
-rw-r--r-- | compilerplugins/clang/loopvartoosmall.cxx | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/compilerplugins/clang/loopvartoosmall.cxx b/compilerplugins/clang/loopvartoosmall.cxx index 2fd53e44dd64..cee6f0247e54 100644 --- a/compilerplugins/clang/loopvartoosmall.cxx +++ b/compilerplugins/clang/loopvartoosmall.cxx @@ -103,8 +103,8 @@ bool LoopVarTooSmall::VisitForStmt( const ForStmt* stmt ) report( DiagnosticsEngine::Warning, "loop index type is smaller than length type. " + qt.getAsString() + " < " + qt2.getAsString(), - stmt->getLocStart()) - << stmt->getSourceRange(); + stmt->getInit()->getLocStart()) + << stmt->getInit()->getSourceRange(); // stmt->getCond()->dump(); } return true; |