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/qv4globalobject.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/qv4globalobject.cpp')
-rw-r--r-- | src/qml/jsruntime/qv4globalobject.cpp | 16 |
1 files changed, 8 insertions, 8 deletions
diff --git a/src/qml/jsruntime/qv4globalobject.cpp b/src/qml/jsruntime/qv4globalobject.cpp index fca49308cc..3ded454f2e 100644 --- a/src/qml/jsruntime/qv4globalobject.cpp +++ b/src/qml/jsruntime/qv4globalobject.cpp @@ -101,16 +101,16 @@ static QString escape(const QString &input) output.append(QChar(uc)); } else { output.append('%'); - output.append(QChar(toHex(uc >> 4))); - output.append(QChar(toHex(uc))); + output.append(QLatin1Char(toHex(uc >> 4))); + output.append(QLatin1Char(toHex(uc))); } } else { output.append('%'); output.append('u'); - output.append(QChar(toHex(uc >> 12))); - output.append(QChar(toHex(uc >> 8))); - output.append(QChar(toHex(uc >> 4))); - output.append(QChar(toHex(uc))); + output.append(QLatin1Char(toHex(uc >> 12))); + output.append(QLatin1Char(toHex(uc >> 8))); + output.append(QLatin1Char(toHex(uc >> 4))); + output.append(QLatin1Char(toHex(uc))); } } return output; @@ -396,7 +396,7 @@ ReturnedValue EvalFunction::evalCall(CallData *callData, bool directCall) const QString code = callData->args[0].stringValue()->toQString(); bool inheritContext = !ctx->strictMode; - Script script(ctx, code, QString("eval code")); + Script script(ctx, code, QStringLiteral("eval code")); script.strictMode = (directCall && parentContext->strictMode); script.inheritContext = inheritContext; script.parse(); @@ -558,7 +558,7 @@ ReturnedValue GlobalFunctions::method_parseFloat(SimpleCallContext *ctx) if (trimmed.startsWith(QLatin1String("Infinity")) || trimmed.startsWith(QLatin1String("+Infinity"))) return Encode(Q_INFINITY); - if (trimmed.startsWith("-Infinity")) + if (trimmed.startsWith(QStringLiteral("-Infinity"))) return Encode(-Q_INFINITY); QByteArray ba = trimmed.toLatin1(); bool ok; |