Fix compiler warnings.
authorErik Verbruggen <erik.verbruggen@me.com>
Wed, 23 Jan 2013 10:04:48 +0000 (11:04 +0100)
committerLars Knoll <lars.knoll@digia.com>
Wed, 23 Jan 2013 10:56:54 +0000 (11:56 +0100)
The second call method in EvalFunction was hiding an overloaded virtual
function, hence the name change.

Change-Id: Ic333d1e7359df97ff25dace87c80b40a939a4cea
Reviewed-by: Lars Knoll <lars.knoll@digia.com>
qmljs_runtime.cpp
qv4dateobject.cpp
qv4globalobject.cpp
qv4globalobject.h
qv4jsonobject.cpp

index b6750ff..dddf89a 100644 (file)
@@ -742,7 +742,7 @@ Value __qmljs_call_activation_property(ExecutionContext *context, String *name,
     Value thisObject = base ? Value::fromObject(base) : Value::undefinedValue();
 
     if (o == context->engine->evalFunction && name == context->engine->id_eval)
-        return static_cast<EvalFunction *>(o)->call(context, thisObject, args, argc, true);
+        return static_cast<EvalFunction *>(o)->evalCall(context, thisObject, args, argc, true);
 
     return o->call(context, thisObject, args, argc);
 }
index a6e5119..3038e72 100644 (file)
@@ -802,6 +802,7 @@ Value DatePrototype::method_UTC(ExecutionContext *ctx)
 
 Value DatePrototype::method_now(ExecutionContext *ctx)
 {
+    Q_UNUSED(ctx);
     double t = currentTime();
     return Value::fromDouble(t);
 }
index 1857eee..67c1759 100644 (file)
@@ -313,7 +313,7 @@ EvalFunction::EvalFunction(ExecutionContext *scope)
     name = scope->engine->id_eval;
 }
 
-Value EvalFunction::call(ExecutionContext *context, Value /*thisObject*/, Value *args, int argc, bool directCall)
+Value EvalFunction::evalCall(ExecutionContext *context, Value /*thisObject*/, Value *args, int argc, bool directCall)
 {
     if (argc < 1)
         return Value::undefinedValue();
@@ -363,7 +363,7 @@ Value EvalFunction::call(ExecutionContext *context, Value /*thisObject*/, Value
 Value EvalFunction::call(ExecutionContext *context, Value thisObject, Value *args, int argc)
 {
     // indirect call
-    return call(context, thisObject, args, argc, false);
+    return evalCall(context, thisObject, args, argc, false);
 }
 
 QQmlJS::VM::Function *EvalFunction::parseSource(QQmlJS::VM::ExecutionContext *ctx,
index 84668cf..2072227 100644 (file)
@@ -58,7 +58,7 @@ struct EvalFunction : FunctionObject
                                              bool inheritContext);
 
     virtual Value call(ExecutionContext *context, Value thisObject, Value *args, int argc);
-    Value call(ExecutionContext *context, Value thisObject, Value *args, int argc, bool directCall);
+    Value evalCall(ExecutionContext *context, Value thisObject, Value *args, int argc, bool directCall);
 };
 
 struct GlobalFunctions
index 77645d2..d8e793e 100644 (file)
@@ -103,6 +103,7 @@ Value JsonObject::method_parse(ExecutionContext *ctx)
 
 Value JsonObject::method_stringify(ExecutionContext *ctx)
 {
+    Q_UNUSED(ctx);
     assert(!"Not implemented");
 }