Fix build on Android with -developer-build
authorSimon Hausmann <simon.hausmann@digia.com>
Fri, 11 Oct 2013 11:22:19 +0000 (13:22 +0200)
committerThe Qt Project <gerrit-noreply@qt-project.org>
Fri, 11 Oct 2013 14:01:24 +0000 (16:01 +0200)
That configuration implies -Werror for some kind of warnings. This patch fixes

   * Mix of different types in conditional (qv4isel_masm.cpp)
   * Noreturn function returning instead of calling another noreturn function at the end (qv4engine_cxxabi.cpp)
   * An out-of-line function being declared inline

Task-Number: QTBUG-33998
Change-Id: I3ba58dcadeac6774c5de63e6bb551354a2f23332
Reviewed-by: Lars Knoll <lars.knoll@digia.com>
src/qml/compiler/qv4isel_masm.cpp
src/qml/jsruntime/qv4engine_cxxabi.cpp
src/qml/jsruntime/qv4value_def_p.h

index 6fb8393..574b4e2 100644 (file)
@@ -2239,8 +2239,8 @@ bool InstructionSelection::visitCJumpStrictNullUndefined(V4IR::Type nullOrUndef,
 
     Assembler::RelationalCondition cond = binop->op == V4IR::OpStrictEqual ? Assembler::Equal
                                                                            : Assembler::NotEqual;
-    const Assembler::TrustedImm32 tag(nullOrUndef == V4IR::NullType ? QV4::Value::_Null_Type
-                                                                    : QV4::Value::Undefined_Type);
+    const Assembler::TrustedImm32 tag(nullOrUndef == V4IR::NullType ? int(QV4::Value::_Null_Type)
+                                                                    : int(QV4::Value::Undefined_Type));
     _as->generateCJumpOnCompare(cond, tagReg, tag, _block, trueBlock, falseBlock);
     return true;
 }
index 6141753..02a6b9b 100644 (file)
@@ -131,6 +131,7 @@ void ExecutionEngine::rethrowInternal()
 
     globals->caughtExceptions = 0;
     _Unwind_RaiseException(&exception->unwindHeader);
+    std::terminate();
 }
 
 QT_END_NAMESPACE
index c8d03cf..82f8d02 100644 (file)
@@ -242,7 +242,7 @@ struct Q_QML_EXPORT Value
     void setDouble(double d) { dbl = d; }
     bool isNaN() const { return (tag & QV4::Value::NotDouble_Mask) == QV4::Value::NaN_Mask; }
 #endif
-    inline bool isString() const;
+    bool isString() const;
     inline bool isObject() const;
     inline bool isInt32() {
         if (tag == _Integer_Type)