diff options
author | Oleg Shparber <trollixx@gmail.com> | 2014-11-28 00:20:29 -0800 |
---|---|---|
committer | Oleg Shparber <trollixx@gmail.com> | 2014-12-12 03:50:50 +0100 |
commit | fdd367efd705f958af1f70413e726d337e8ec1ca (patch) | |
tree | 5bbbb76480988a55141445996933e2330d23a563 /src/qml/jsruntime/qv4regexpobject.cpp | |
parent | f43928f6023f435dfe3e600dd4474cd2c7a92e16 (diff) |
Add default parameter value for ExecutionEngine::newString()
Change-Id: I8efbfb07ea61e2c6d03eeb79671006d209e4d48e
Reviewed-by: Simon Hausmann <simon.hausmann@digia.com>
Diffstat (limited to 'src/qml/jsruntime/qv4regexpobject.cpp')
-rw-r--r-- | src/qml/jsruntime/qv4regexpobject.cpp | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/src/qml/jsruntime/qv4regexpobject.cpp b/src/qml/jsruntime/qv4regexpobject.cpp index 7191a16235..ff78cf3e13 100644 --- a/src/qml/jsruntime/qv4regexpobject.cpp +++ b/src/qml/jsruntime/qv4regexpobject.cpp @@ -447,7 +447,7 @@ ReturnedValue RegExpPrototype::method_get_lastMatch_n(CallContext *ctx) ScopedArrayObject lastMatch(scope, static_cast<RegExpCtor*>(ctx->d()->engine->regExpCtor.objectValue())->lastMatch()); ScopedValue result(scope, lastMatch ? lastMatch->getIndexed(index) : Encode::undefined()); if (result->isUndefined()) - return ctx->d()->engine->newString(QString())->asReturnedValue(); + return ctx->d()->engine->newString()->asReturnedValue(); return result.asReturnedValue(); } @@ -457,7 +457,7 @@ ReturnedValue RegExpPrototype::method_get_lastParen(CallContext *ctx) ScopedArrayObject lastMatch(scope, static_cast<RegExpCtor*>(ctx->d()->engine->regExpCtor.objectValue())->lastMatch()); ScopedValue result(scope, lastMatch ? lastMatch->getIndexed(lastMatch->getLength() - 1) : Encode::undefined()); if (result->isUndefined()) - return ctx->d()->engine->newString(QString())->asReturnedValue(); + return ctx->d()->engine->newString()->asReturnedValue(); return result.asReturnedValue(); } |