From 0130fc27cc556819727e83c1a02162fb3817ac9a Mon Sep 17 00:00:00 2001 From: "alexey.lysiuk" Date: Sat, 18 Mar 2017 14:31:15 +0200 Subject: [PATCH] Fixed compilation with GCC/Clang src/scripting/backend/codegen.cpp:317:35: error: cannot initialize return object of type 'FxExpression *' with an rvalue of type 'bool' --- src/scripting/backend/codegen.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/scripting/backend/codegen.cpp b/src/scripting/backend/codegen.cpp index bb6a76480e..11852eb20b 100644 --- a/src/scripting/backend/codegen.cpp +++ b/src/scripting/backend/codegen.cpp @@ -314,7 +314,7 @@ static bool AreCompatiblePointerTypes(PType *dest, PType *source, bool forcompar static FxExpression *StringConstToChar(FxExpression *basex) { - if (!basex->isConstant()) return false; + if (!basex->isConstant()) return nullptr; // Allow single character string literals be convertible to integers. // This serves as workaround for not being able to use single quoted literals because those are taken for names. ExpVal constval = static_cast(basex)->GetValue();