loplugin:constantparam
and tweak the plugin to handle a crash seen with clang-9 Change-Id: Ie1ccf80c16a20dbca58e5bd081af13f75cf5ac8f Reviewed-on: https://gerrit.libreoffice.org/75850 Tested-by: Jenkins Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
This commit is contained in:
@@ -168,9 +168,10 @@ std::string ConstantParam::getCallValue(const Expr* arg)
|
||||
}
|
||||
arg = arg->IgnoreParenCasts();
|
||||
// ignore this, it seems to trigger an infinite recursion
|
||||
if (isa<UnaryExprOrTypeTraitExpr>(arg)) {
|
||||
if (isa<UnaryExprOrTypeTraitExpr>(arg))
|
||||
return "unknown1";
|
||||
}
|
||||
if (arg->isValueDependent())
|
||||
return "unknown2";
|
||||
APSInt x1;
|
||||
if (compat::EvaluateAsInt(arg, x1, compiler.getASTContext()))
|
||||
{
|
||||
|
Reference in New Issue
Block a user