From f6c0550c41cf009fa9c9f19261f8b8f406bba1cb Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Daniel=20Marjam=C3=A4ki?= Date: Sat, 28 Sep 2019 11:55:06 +0200 Subject: [PATCH] ExprEngine: Do not bailout if function type is not known if the result is not used anyway --- lib/exprengine.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/lib/exprengine.cpp b/lib/exprengine.cpp index 770a00ff7..e531a9e3a 100644 --- a/lib/exprengine.cpp +++ b/lib/exprengine.cpp @@ -820,7 +820,7 @@ static ExprEngine::ValuePtr executeFunctionCall(const Token *tok, Data &data) } } - if (!tok->valueType()) + if (!tok->valueType() && tok->astParent()) throw std::runtime_error("Expression '" + tok->expressionString() + "' has unknown type!"); auto val = getValueRangeFromValueType(data.getNewSymbolName(), tok->valueType(), *data.settings);