diff options
author | Erik Verbruggen <erik.verbruggen@digia.com> | 2013-11-01 12:38:32 +0100 |
---|---|---|
committer | The Qt Project <gerrit-noreply@qt-project.org> | 2013-11-04 02:16:04 +0100 |
commit | a79e400150e9d550cc4ddc0c0497778d8b78fe5d (patch) | |
tree | 5a66670d4c31aaf0d356042b6fe607728e237b5b /src/qml/jsruntime/qv4context.cpp | |
parent | b5991ce2a61219bda5a7fa6e33f323158d1eb78b (diff) |
Fix various compiler warnings in order to remove warn_off in the near future
Change-Id: Ic0492fbe31a1e134674bc6c20381f735dd6d5b7a
Reviewed-by: Simon Hausmann <simon.hausmann@digia.com>
Diffstat (limited to 'src/qml/jsruntime/qv4context.cpp')
-rw-r--r-- | src/qml/jsruntime/qv4context.cpp | 10 |
1 files changed, 5 insertions, 5 deletions
diff --git a/src/qml/jsruntime/qv4context.cpp b/src/qml/jsruntime/qv4context.cpp index ece31822b5..a8628d6fa8 100644 --- a/src/qml/jsruntime/qv4context.cpp +++ b/src/qml/jsruntime/qv4context.cpp @@ -85,7 +85,7 @@ CallContext *ExecutionContext::newCallContext(void *stackSpace, SafeValue *local if (function->varCount) std::fill(c->locals, c->locals + function->varCount, Primitive::undefinedValue()); - if (callData->argc < function->formalParameterCount) { + if (callData->argc < static_cast<int>(function->formalParameterCount)) { #ifndef QT_NO_DEBUG Q_ASSERT(function->formalParameterCount <= QV4::Global::ReservedArgumentCount); #endif @@ -128,7 +128,7 @@ CallContext *ExecutionContext::newCallContext(FunctionObject *function, CallData c->callData = reinterpret_cast<CallData *>(c->locals + function->varCount); ::memcpy(c->callData, callData, sizeof(CallData) + (callData->argc - 1) * sizeof(SafeValue)); - if (callData->argc < function->formalParameterCount) + if (callData->argc < static_cast<int>(function->formalParameterCount)) std::fill(c->callData->args + c->callData->argc, c->callData->args + function->formalParameterCount, Primitive::undefinedValue()); c->callData->argc = qMax((uint)callData->argc, function->formalParameterCount); @@ -309,13 +309,13 @@ bool ExecutionContext::deleteProperty(const StringRef name) } if (strictMode) - throwSyntaxError(QString("Can't delete property %1").arg(name->toQString())); + throwSyntaxError(QStringLiteral("Can't delete property %1").arg(name->toQString())); return true; } bool CallContext::needsOwnArguments() const { - return function->needsActivation || callData->argc < function->formalParameterCount; + return function->needsActivation || callData->argc < static_cast<int>(function->formalParameterCount); } void ExecutionContext::mark() @@ -328,7 +328,7 @@ void ExecutionContext::mark() outer->mark(); callData->thisObject.mark(); - for (unsigned arg = 0; arg < callData->argc; ++arg) + for (int arg = 0; arg < callData->argc; ++arg) callData->args[arg].mark(); if (type >= Type_CallContext) { |