[Libreoffice-commits] core.git: compilerplugins/clang
Noel Grandin
noel at peralex.com
Thu Jun 25 05:01:20 PDT 2015
compilerplugins/clang/stringconstant.cxx | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
New commits:
commit f53c186b8d2f5a13a3a644dbff7f21548c32c4d4
Author: Noel Grandin <noel at peralex.com>
Date: Thu Jun 25 14:00:26 2015 +0200
my previous fix triggered an assert in clang
Change-Id: I67b8dec0d49032134a1b588363e72fa88f5993f7
diff --git a/compilerplugins/clang/stringconstant.cxx b/compilerplugins/clang/stringconstant.cxx
index 5ffec1b..20ff2a9 100644
--- a/compilerplugins/clang/stringconstant.cxx
+++ b/compilerplugins/clang/stringconstant.cxx
@@ -1191,7 +1191,7 @@ void StringConstant::handleOUStringCtor(
&& e3->getArg(0)->IgnoreParenImpCasts()->isIntegerConstantExpr(
res, compiler.getASTContext()))
{
- if (res > static_cast<APSInt>(0) && res <= static_cast<APSInt>(127)) {
+ if (res.getSExtValue() > 0 && res.getSExtValue() <= 127) {
report(
DiagnosticsEngine::Warning,
("in call of %0, replace OUString constructed from a (non-NUL)"
More information about the Libreoffice-commits
mailing list