Chromium Code Reviews| Index: Source/bindings/tests/results/V8TestObject.cpp |
| diff --git a/Source/bindings/tests/results/V8TestObject.cpp b/Source/bindings/tests/results/V8TestObject.cpp |
| index 10edd5c1c08cba99f0792a23620823fe0679fa49..5cdbb3c3322e7c4697c274c7f56bf126ce9176c7 100644 |
| --- a/Source/bindings/tests/results/V8TestObject.cpp |
| +++ b/Source/bindings/tests/results/V8TestObject.cpp |
| @@ -5238,7 +5238,8 @@ static void staticVoidMethodMethodCallback(const v8::FunctionCallbackInfo<v8::Va |
| static void dateMethodMethod(const v8::FunctionCallbackInfo<v8::Value>& info) |
| { |
| TestObject* impl = V8TestObject::toNative(info.Holder()); |
| - v8SetReturnValue(info, v8DateOrNaN(impl->dateMethod(), info.GetIsolate())); |
| + double result = impl->dateMethod(); |
| + v8SetReturnValue(info, v8DateOrNaN(result, info.GetIsolate())); |
| } |
| static void dateMethodMethodCallback(const v8::FunctionCallbackInfo<v8::Value>& info) |
| @@ -5251,7 +5252,8 @@ static void dateMethodMethodCallback(const v8::FunctionCallbackInfo<v8::Value>& |
| static void stringMethodMethod(const v8::FunctionCallbackInfo<v8::Value>& info) |
| { |
| TestObject* impl = V8TestObject::toNative(info.Holder()); |
| - v8SetReturnValueString(info, impl->stringMethod(), info.GetIsolate()); |
| + String result = impl->stringMethod(); |
| + v8SetReturnValueString(info, result, info.GetIsolate()); |
| } |
| static void stringMethodMethodCallback(const v8::FunctionCallbackInfo<v8::Value>& info) |
| @@ -5264,7 +5266,8 @@ static void stringMethodMethodCallback(const v8::FunctionCallbackInfo<v8::Value> |
| static void byteStringMethodMethod(const v8::FunctionCallbackInfo<v8::Value>& info) |
| { |
| TestObject* impl = V8TestObject::toNative(info.Holder()); |
| - v8SetReturnValueString(info, impl->byteStringMethod(), info.GetIsolate()); |
| + String result = impl->byteStringMethod(); |
| + v8SetReturnValueString(info, result, info.GetIsolate()); |
| } |
| static void byteStringMethodMethodCallback(const v8::FunctionCallbackInfo<v8::Value>& info) |
| @@ -5277,7 +5280,8 @@ static void byteStringMethodMethodCallback(const v8::FunctionCallbackInfo<v8::Va |
| static void scalarValueStringMethodMethod(const v8::FunctionCallbackInfo<v8::Value>& info) |
| { |
| TestObject* impl = V8TestObject::toNative(info.Holder()); |
| - v8SetReturnValueString(info, impl->scalarValueStringMethod(), info.GetIsolate()); |
| + String result = impl->scalarValueStringMethod(); |
| + v8SetReturnValueString(info, result, info.GetIsolate()); |
| } |
| static void scalarValueStringMethodMethodCallback(const v8::FunctionCallbackInfo<v8::Value>& info) |
| @@ -5290,7 +5294,8 @@ static void scalarValueStringMethodMethodCallback(const v8::FunctionCallbackInfo |
| static void readonlyDOMTimeStampMethodMethod(const v8::FunctionCallbackInfo<v8::Value>& info) |
| { |
| TestObject* impl = V8TestObject::toNative(info.Holder()); |
| - v8SetReturnValue(info, static_cast<double>(impl->readonlyDOMTimeStampMethod())); |
| + unsigned long long result = impl->readonlyDOMTimeStampMethod(); |
| + v8SetReturnValue(info, static_cast<double>(result)); |
| } |
| static void readonlyDOMTimeStampMethodMethodCallback(const v8::FunctionCallbackInfo<v8::Value>& info) |
| @@ -5303,7 +5308,8 @@ static void readonlyDOMTimeStampMethodMethodCallback(const v8::FunctionCallbackI |
| static void booleanMethodMethod(const v8::FunctionCallbackInfo<v8::Value>& info) |
| { |
| TestObject* impl = V8TestObject::toNative(info.Holder()); |
| - v8SetReturnValueBool(info, impl->booleanMethod()); |
| + bool result = impl->booleanMethod(); |
| + v8SetReturnValueBool(info, result); |
| } |
| static void booleanMethodMethodCallback(const v8::FunctionCallbackInfo<v8::Value>& info) |
| @@ -5316,7 +5322,8 @@ static void booleanMethodMethodCallback(const v8::FunctionCallbackInfo<v8::Value |
| static void byteMethodMethod(const v8::FunctionCallbackInfo<v8::Value>& info) |
| { |
| TestObject* impl = V8TestObject::toNative(info.Holder()); |
| - v8SetReturnValueInt(info, impl->byteMethod()); |
| + int result = impl->byteMethod(); |
| + v8SetReturnValueInt(info, result); |
| } |
| static void byteMethodMethodCallback(const v8::FunctionCallbackInfo<v8::Value>& info) |
| @@ -5329,7 +5336,8 @@ static void byteMethodMethodCallback(const v8::FunctionCallbackInfo<v8::Value>& |
| static void doubleMethodMethod(const v8::FunctionCallbackInfo<v8::Value>& info) |
| { |
| TestObject* impl = V8TestObject::toNative(info.Holder()); |
| - v8SetReturnValue(info, impl->doubleMethod()); |
| + double result = impl->doubleMethod(); |
| + v8SetReturnValue(info, result); |
| } |
| static void doubleMethodMethodCallback(const v8::FunctionCallbackInfo<v8::Value>& info) |
| @@ -5342,7 +5350,8 @@ static void doubleMethodMethodCallback(const v8::FunctionCallbackInfo<v8::Value> |
| static void floatMethodMethod(const v8::FunctionCallbackInfo<v8::Value>& info) |
| { |
| TestObject* impl = V8TestObject::toNative(info.Holder()); |
| - v8SetReturnValue(info, impl->floatMethod()); |
| + float result = impl->floatMethod(); |
| + v8SetReturnValue(info, result); |
| } |
| static void floatMethodMethodCallback(const v8::FunctionCallbackInfo<v8::Value>& info) |
| @@ -5355,7 +5364,8 @@ static void floatMethodMethodCallback(const v8::FunctionCallbackInfo<v8::Value>& |
| static void longMethodMethod(const v8::FunctionCallbackInfo<v8::Value>& info) |
| { |
| TestObject* impl = V8TestObject::toNative(info.Holder()); |
| - v8SetReturnValueInt(info, impl->longMethod()); |
| + int result = impl->longMethod(); |
| + v8SetReturnValueInt(info, result); |
| } |
| static void longMethodMethodCallback(const v8::FunctionCallbackInfo<v8::Value>& info) |
| @@ -5368,7 +5378,8 @@ static void longMethodMethodCallback(const v8::FunctionCallbackInfo<v8::Value>& |
| static void longLongMethodMethod(const v8::FunctionCallbackInfo<v8::Value>& info) |
| { |
| TestObject* impl = V8TestObject::toNative(info.Holder()); |
| - v8SetReturnValue(info, static_cast<double>(impl->longLongMethod())); |
| + long long result = impl->longLongMethod(); |
|
Daniel Bratell
2014/07/11 12:29:39
Here it will possibly do two type conversions. Fir
|
| + v8SetReturnValue(info, static_cast<double>(result)); |
| } |
| static void longLongMethodMethodCallback(const v8::FunctionCallbackInfo<v8::Value>& info) |
| @@ -5381,7 +5392,8 @@ static void longLongMethodMethodCallback(const v8::FunctionCallbackInfo<v8::Valu |
| static void octetMethodMethod(const v8::FunctionCallbackInfo<v8::Value>& info) |
| { |
| TestObject* impl = V8TestObject::toNative(info.Holder()); |
| - v8SetReturnValueUnsigned(info, impl->octetMethod()); |
| + unsigned result = impl->octetMethod(); |
| + v8SetReturnValueUnsigned(info, result); |
| } |
| static void octetMethodMethodCallback(const v8::FunctionCallbackInfo<v8::Value>& info) |
| @@ -5394,7 +5406,8 @@ static void octetMethodMethodCallback(const v8::FunctionCallbackInfo<v8::Value>& |
| static void shortMethodMethod(const v8::FunctionCallbackInfo<v8::Value>& info) |
| { |
| TestObject* impl = V8TestObject::toNative(info.Holder()); |
| - v8SetReturnValueInt(info, impl->shortMethod()); |
| + int result = impl->shortMethod(); |
| + v8SetReturnValueInt(info, result); |
| } |
| static void shortMethodMethodCallback(const v8::FunctionCallbackInfo<v8::Value>& info) |
| @@ -5407,7 +5420,8 @@ static void shortMethodMethodCallback(const v8::FunctionCallbackInfo<v8::Value>& |
| static void unsignedLongMethodMethod(const v8::FunctionCallbackInfo<v8::Value>& info) |
| { |
| TestObject* impl = V8TestObject::toNative(info.Holder()); |
| - v8SetReturnValueUnsigned(info, impl->unsignedLongMethod()); |
| + unsigned result = impl->unsignedLongMethod(); |
| + v8SetReturnValueUnsigned(info, result); |
| } |
| static void unsignedLongMethodMethodCallback(const v8::FunctionCallbackInfo<v8::Value>& info) |
| @@ -5420,7 +5434,8 @@ static void unsignedLongMethodMethodCallback(const v8::FunctionCallbackInfo<v8:: |
| static void unsignedLongLongMethodMethod(const v8::FunctionCallbackInfo<v8::Value>& info) |
| { |
| TestObject* impl = V8TestObject::toNative(info.Holder()); |
| - v8SetReturnValue(info, static_cast<double>(impl->unsignedLongLongMethod())); |
| + unsigned long long result = impl->unsignedLongLongMethod(); |
| + v8SetReturnValue(info, static_cast<double>(result)); |
| } |
| static void unsignedLongLongMethodMethodCallback(const v8::FunctionCallbackInfo<v8::Value>& info) |
| @@ -5433,7 +5448,8 @@ static void unsignedLongLongMethodMethodCallback(const v8::FunctionCallbackInfo< |
| static void unsignedShortMethodMethod(const v8::FunctionCallbackInfo<v8::Value>& info) |
| { |
| TestObject* impl = V8TestObject::toNative(info.Holder()); |
| - v8SetReturnValueUnsigned(info, impl->unsignedShortMethod()); |
| + unsigned result = impl->unsignedShortMethod(); |
| + v8SetReturnValueUnsigned(info, result); |
| } |
| static void unsignedShortMethodMethodCallback(const v8::FunctionCallbackInfo<v8::Value>& info) |
| @@ -5823,7 +5839,8 @@ static void voidMethodUnsignedShortArgMethodCallback(const v8::FunctionCallbackI |
| static void testInterfaceEmptyMethodMethod(const v8::FunctionCallbackInfo<v8::Value>& info) |
| { |
| TestObject* impl = V8TestObject::toNative(info.Holder()); |
| - v8SetReturnValue(info, impl->testInterfaceEmptyMethod()); |
| + RefPtr<TestInterfaceEmpty> result = impl->testInterfaceEmptyMethod(); |
|
Daniel Bratell
2014/07/11 12:29:39
Is this equivalent?
|
| + v8SetReturnValue(info, result.release()); |
| } |
| static void testInterfaceEmptyMethodMethodCallback(const v8::FunctionCallbackInfo<v8::Value>& info) |
| @@ -5885,7 +5902,8 @@ static void voidMethodLongArgTestInterfaceEmptyArgMethodCallback(const v8::Funct |
| static void voidCallbackFunctionMethodMethod(const v8::FunctionCallbackInfo<v8::Value>& info) |
| { |
| TestObject* impl = V8TestObject::toNative(info.Holder()); |
| - v8SetReturnValue(info, impl->voidCallbackFunctionMethod().v8Value()); |
| + ScriptValue result = impl->voidCallbackFunctionMethod(); |
| + v8SetReturnValue(info, result.v8Value()); |
| } |
| static void voidCallbackFunctionMethodMethodCallback(const v8::FunctionCallbackInfo<v8::Value>& info) |
| @@ -5898,7 +5916,8 @@ static void voidCallbackFunctionMethodMethodCallback(const v8::FunctionCallbackI |
| static void anyCallbackFunctionOptionalAnyArgMethodMethod(const v8::FunctionCallbackInfo<v8::Value>& info) |
| { |
| TestObject* impl = V8TestObject::toNative(info.Holder()); |
| - v8SetReturnValue(info, impl->anyCallbackFunctionOptionalAnyArgMethod().v8Value()); |
| + ScriptValue result = impl->anyCallbackFunctionOptionalAnyArgMethod(); |
| + v8SetReturnValue(info, result.v8Value()); |
| } |
| static void anyCallbackFunctionOptionalAnyArgMethodMethodCallback(const v8::FunctionCallbackInfo<v8::Value>& info) |
| @@ -5957,7 +5976,8 @@ static void voidMethodAnyCallbackFunctionOptionalAnyArgMethodCallback(const v8:: |
| static void compareHowMethodMethod(const v8::FunctionCallbackInfo<v8::Value>& info) |
| { |
| TestObject* impl = V8TestObject::toNative(info.Holder()); |
| - v8SetReturnValue(info, impl->compareHowMethod()); |
| + Range::CompareHow result = impl->compareHowMethod(); |
| + v8SetReturnValue(info, result.release()); |
| } |
| static void compareHowMethodMethodCallback(const v8::FunctionCallbackInfo<v8::Value>& info) |
| @@ -5970,7 +5990,8 @@ static void compareHowMethodMethodCallback(const v8::FunctionCallbackInfo<v8::Va |
| static void anyMethodMethod(const v8::FunctionCallbackInfo<v8::Value>& info) |
| { |
| TestObject* impl = V8TestObject::toNative(info.Holder()); |
| - v8SetReturnValue(info, impl->anyMethod().v8Value()); |
| + ScriptValue result = impl->anyMethod(); |
| + v8SetReturnValue(info, result.v8Value()); |
| } |
| static void anyMethodMethodCallback(const v8::FunctionCallbackInfo<v8::Value>& info) |
| @@ -6190,7 +6211,8 @@ static void voidMethodNodeArgMethodCallback(const v8::FunctionCallbackInfo<v8::V |
| static void arrayBufferMethodMethod(const v8::FunctionCallbackInfo<v8::Value>& info) |
| { |
| TestObject* impl = V8TestObject::toNative(info.Holder()); |
| - v8SetReturnValue(info, impl->arrayBufferMethod()); |
| + RefPtr<ArrayBuffer> result = impl->arrayBufferMethod(); |
| + v8SetReturnValue(info, result.release()); |
| } |
| static void arrayBufferMethodMethodCallback(const v8::FunctionCallbackInfo<v8::Value>& info) |
| @@ -6203,7 +6225,8 @@ static void arrayBufferMethodMethodCallback(const v8::FunctionCallbackInfo<v8::V |
| static void arrayBufferViewMethodMethod(const v8::FunctionCallbackInfo<v8::Value>& info) |
| { |
| TestObject* impl = V8TestObject::toNative(info.Holder()); |
| - v8SetReturnValue(info, impl->arrayBufferViewMethod()); |
| + RefPtr<ArrayBufferView> result = impl->arrayBufferViewMethod(); |
| + v8SetReturnValue(info, result.release()); |
| } |
| static void arrayBufferViewMethodMethodCallback(const v8::FunctionCallbackInfo<v8::Value>& info) |
| @@ -6216,7 +6239,8 @@ static void arrayBufferViewMethodMethodCallback(const v8::FunctionCallbackInfo<v |
| static void float32ArrayMethodMethod(const v8::FunctionCallbackInfo<v8::Value>& info) |
| { |
| TestObject* impl = V8TestObject::toNative(info.Holder()); |
| - v8SetReturnValue(info, impl->float32ArrayMethod()); |
| + RefPtr<Float32Array> result = impl->float32ArrayMethod(); |
| + v8SetReturnValue(info, result.release()); |
| } |
| static void float32ArrayMethodMethodCallback(const v8::FunctionCallbackInfo<v8::Value>& info) |
| @@ -6229,7 +6253,8 @@ static void float32ArrayMethodMethodCallback(const v8::FunctionCallbackInfo<v8:: |
| static void int32ArrayMethodMethod(const v8::FunctionCallbackInfo<v8::Value>& info) |
| { |
| TestObject* impl = V8TestObject::toNative(info.Holder()); |
| - v8SetReturnValue(info, impl->int32ArrayMethod()); |
| + RefPtr<Int32Array> result = impl->int32ArrayMethod(); |
| + v8SetReturnValue(info, result.release()); |
| } |
| static void int32ArrayMethodMethodCallback(const v8::FunctionCallbackInfo<v8::Value>& info) |
| @@ -6242,7 +6267,8 @@ static void int32ArrayMethodMethodCallback(const v8::FunctionCallbackInfo<v8::Va |
| static void uint8ArrayMethodMethod(const v8::FunctionCallbackInfo<v8::Value>& info) |
| { |
| TestObject* impl = V8TestObject::toNative(info.Holder()); |
| - v8SetReturnValue(info, impl->uint8ArrayMethod()); |
| + RefPtr<Uint8Array> result = impl->uint8ArrayMethod(); |
| + v8SetReturnValue(info, result.release()); |
| } |
| static void uint8ArrayMethodMethodCallback(const v8::FunctionCallbackInfo<v8::Value>& info) |
| @@ -6393,7 +6419,8 @@ static void voidMethodUint8ArrayArgMethodCallback(const v8::FunctionCallbackInfo |
| static void longArrayMethodMethod(const v8::FunctionCallbackInfo<v8::Value>& info) |
| { |
| TestObject* impl = V8TestObject::toNative(info.Holder()); |
| - v8SetReturnValue(info, v8Array(impl->longArrayMethod(), info.Holder(), info.GetIsolate())); |
| + Vector<int> result = impl->longArrayMethod(); |
|
Daniel Bratell
2014/07/11 12:29:39
Looks like this might introduce a vector copy whic
|
| + v8SetReturnValue(info, v8Array(result, info.Holder(), info.GetIsolate())); |
| } |
| static void longArrayMethodMethodCallback(const v8::FunctionCallbackInfo<v8::Value>& info) |
| @@ -6406,7 +6433,8 @@ static void longArrayMethodMethodCallback(const v8::FunctionCallbackInfo<v8::Val |
| static void stringArrayMethodMethod(const v8::FunctionCallbackInfo<v8::Value>& info) |
| { |
| TestObject* impl = V8TestObject::toNative(info.Holder()); |
| - v8SetReturnValue(info, v8Array(impl->stringArrayMethod(), info.Holder(), info.GetIsolate())); |
| + Vector<String> result = impl->stringArrayMethod(); |
| + v8SetReturnValue(info, v8Array(result, info.Holder(), info.GetIsolate())); |
| } |
| static void stringArrayMethodMethodCallback(const v8::FunctionCallbackInfo<v8::Value>& info) |
| @@ -6419,7 +6447,8 @@ static void stringArrayMethodMethodCallback(const v8::FunctionCallbackInfo<v8::V |
| static void testInterfaceEmptyArrayMethodMethod(const v8::FunctionCallbackInfo<v8::Value>& info) |
| { |
| TestObject* impl = V8TestObject::toNative(info.Holder()); |
| - v8SetReturnValue(info, v8Array(impl->testInterfaceEmptyArrayMethod(), info.Holder(), info.GetIsolate())); |
| + Vector<RefPtr<TestInterfaceEmpty> > result = impl->testInterfaceEmptyArrayMethod(); |
| + v8SetReturnValue(info, v8Array(result, info.Holder(), info.GetIsolate())); |
| } |
| static void testInterfaceEmptyArrayMethodMethodCallback(const v8::FunctionCallbackInfo<v8::Value>& info) |
| @@ -6501,7 +6530,8 @@ static void voidMethodArrayTestInterfaceEmptyArgMethodCallback(const v8::Functio |
| static void longSequenceMethodMethod(const v8::FunctionCallbackInfo<v8::Value>& info) |
| { |
| TestObject* impl = V8TestObject::toNative(info.Holder()); |
| - v8SetReturnValue(info, v8Array(impl->longSequenceMethod(), info.Holder(), info.GetIsolate())); |
| + Vector<int> result = impl->longSequenceMethod(); |
| + v8SetReturnValue(info, v8Array(result, info.Holder(), info.GetIsolate())); |
| } |
| static void longSequenceMethodMethodCallback(const v8::FunctionCallbackInfo<v8::Value>& info) |
| @@ -6514,7 +6544,8 @@ static void longSequenceMethodMethodCallback(const v8::FunctionCallbackInfo<v8:: |
| static void stringSequenceMethodMethod(const v8::FunctionCallbackInfo<v8::Value>& info) |
| { |
| TestObject* impl = V8TestObject::toNative(info.Holder()); |
| - v8SetReturnValue(info, v8Array(impl->stringSequenceMethod(), info.Holder(), info.GetIsolate())); |
| + Vector<String> result = impl->stringSequenceMethod(); |
| + v8SetReturnValue(info, v8Array(result, info.Holder(), info.GetIsolate())); |
| } |
| static void stringSequenceMethodMethodCallback(const v8::FunctionCallbackInfo<v8::Value>& info) |
| @@ -6527,7 +6558,8 @@ static void stringSequenceMethodMethodCallback(const v8::FunctionCallbackInfo<v8 |
| static void testInterfaceEmptySequenceMethodMethod(const v8::FunctionCallbackInfo<v8::Value>& info) |
| { |
| TestObject* impl = V8TestObject::toNative(info.Holder()); |
| - v8SetReturnValue(info, v8Array(impl->testInterfaceEmptySequenceMethod(), info.Holder(), info.GetIsolate())); |
| + Vector<RefPtr<TestInterfaceEmpty> > result = impl->testInterfaceEmptySequenceMethod(); |
| + v8SetReturnValue(info, v8Array(result, info.Holder(), info.GetIsolate())); |
| } |
| static void testInterfaceEmptySequenceMethodMethodCallback(const v8::FunctionCallbackInfo<v8::Value>& info) |
| @@ -6626,7 +6658,8 @@ static void nullableLongMethodMethodCallback(const v8::FunctionCallbackInfo<v8:: |
| static void nullableStringMethodMethod(const v8::FunctionCallbackInfo<v8::Value>& info) |
| { |
| TestObject* impl = V8TestObject::toNative(info.Holder()); |
| - v8SetReturnValueStringOrNull(info, impl->nullableStringMethod(), info.GetIsolate()); |
| + String result = impl->nullableStringMethod(); |
| + v8SetReturnValueStringOrNull(info, result, info.GetIsolate()); |
| } |
| static void nullableStringMethodMethodCallback(const v8::FunctionCallbackInfo<v8::Value>& info) |
| @@ -6639,7 +6672,8 @@ static void nullableStringMethodMethodCallback(const v8::FunctionCallbackInfo<v8 |
| static void nullableTestInterfaceMethodMethod(const v8::FunctionCallbackInfo<v8::Value>& info) |
| { |
| TestObject* impl = V8TestObject::toNative(info.Holder()); |
| - v8SetReturnValue(info, impl->nullableTestInterfaceMethod()); |
| + RefPtr<TestInterfaceImplementation> result = impl->nullableTestInterfaceMethod(); |
| + v8SetReturnValue(info, result.release()); |
| } |
| static void nullableTestInterfaceMethodMethodCallback(const v8::FunctionCallbackInfo<v8::Value>& info) |
| @@ -6765,7 +6799,8 @@ static void voidMethodTestCallbackInterfaceOrNullArgMethodCallback(const v8::Fun |
| static void testEnumMethodMethod(const v8::FunctionCallbackInfo<v8::Value>& info) |
| { |
| TestObject* impl = V8TestObject::toNative(info.Holder()); |
| - v8SetReturnValueString(info, impl->testEnumMethod(), info.GetIsolate()); |
| + String result = impl->testEnumMethod(); |
| + v8SetReturnValueString(info, result, info.GetIsolate()); |
| } |
| static void testEnumMethodMethodCallback(const v8::FunctionCallbackInfo<v8::Value>& info) |
| @@ -6806,7 +6841,8 @@ static void voidMethodTestEnumArgMethodCallback(const v8::FunctionCallbackInfo<v |
| static void dictionaryMethodMethod(const v8::FunctionCallbackInfo<v8::Value>& info) |
| { |
| TestObject* impl = V8TestObject::toNative(info.Holder()); |
| - v8SetReturnValue(info, impl->dictionaryMethod()); |
| + Dictionary result = impl->dictionaryMethod(); |
| + v8SetReturnValue(info, result.release()); |
| } |
| static void dictionaryMethodMethodCallback(const v8::FunctionCallbackInfo<v8::Value>& info) |
| @@ -6819,7 +6855,8 @@ static void dictionaryMethodMethodCallback(const v8::FunctionCallbackInfo<v8::Va |
| static void nodeFilterMethodMethod(const v8::FunctionCallbackInfo<v8::Value>& info) |
| { |
| TestObject* impl = V8TestObject::toNative(info.Holder()); |
| - v8SetReturnValue(info, impl->nodeFilterMethod()); |
| + RefPtrWillBeRawPtr<NodeFilter> result = impl->nodeFilterMethod(); |
| + v8SetReturnValue(info, result.release()); |
| } |
| static void nodeFilterMethodMethodCallback(const v8::FunctionCallbackInfo<v8::Value>& info) |
| @@ -6832,7 +6869,8 @@ static void nodeFilterMethodMethodCallback(const v8::FunctionCallbackInfo<v8::Va |
| static void promiseMethodMethod(const v8::FunctionCallbackInfo<v8::Value>& info) |
| { |
| TestObject* impl = V8TestObject::toNative(info.Holder()); |
| - v8SetReturnValue(info, impl->promiseMethod().v8Value()); |
| + ScriptPromise result = impl->promiseMethod(); |
| + v8SetReturnValue(info, result.v8Value()); |
| } |
| static void promiseMethodMethodCallback(const v8::FunctionCallbackInfo<v8::Value>& info) |
| @@ -6845,7 +6883,8 @@ static void promiseMethodMethodCallback(const v8::FunctionCallbackInfo<v8::Value |
| static void serializedScriptValueMethodMethod(const v8::FunctionCallbackInfo<v8::Value>& info) |
| { |
| TestObject* impl = V8TestObject::toNative(info.Holder()); |
| - v8SetReturnValue(info, impl->serializedScriptValueMethod() ? impl->serializedScriptValueMethod()->deserialize() : v8::Handle<v8::Value>(v8::Null(info.GetIsolate()))); |
| + RefPtr<SerializedScriptValue> result = impl->serializedScriptValueMethod(); |
| + v8SetReturnValue(info, result ? result->deserialize() : v8::Handle<v8::Value>(v8::Null(info.GetIsolate()))); |
| } |
| static void serializedScriptValueMethodMethodCallback(const v8::FunctionCallbackInfo<v8::Value>& info) |
| @@ -6858,7 +6897,8 @@ static void serializedScriptValueMethodMethodCallback(const v8::FunctionCallback |
| static void xPathNSResolverMethodMethod(const v8::FunctionCallbackInfo<v8::Value>& info) |
| { |
| TestObject* impl = V8TestObject::toNative(info.Holder()); |
| - v8SetReturnValue(info, impl->xPathNSResolverMethod()); |
| + RefPtrWillBeRawPtr<XPathNSResolver> result = impl->xPathNSResolverMethod(); |
| + v8SetReturnValue(info, result.release()); |
| } |
| static void xPathNSResolverMethodMethodCallback(const v8::FunctionCallbackInfo<v8::Value>& info) |
| @@ -7120,12 +7160,14 @@ static void stringMethodOptionalLongArgMethod(const v8::FunctionCallbackInfo<v8: |
| v8::TryCatch block; |
| V8RethrowTryCatchScope rethrow(block); |
| if (UNLIKELY(info.Length() <= 0)) { |
| - v8SetReturnValueString(info, impl->stringMethodOptionalLongArg(), info.GetIsolate()); |
| + String result = impl->stringMethodOptionalLongArg(); |
| + v8SetReturnValueString(info, result, info.GetIsolate()); |
| return; |
| } |
| TONATIVE_VOID_EXCEPTIONSTATE_INTERNAL(optionalLongArg, toInt32(info[0], exceptionState), exceptionState); |
| } |
| - v8SetReturnValueString(info, impl->stringMethodOptionalLongArg(optionalLongArg), info.GetIsolate()); |
| + String result = impl->stringMethodOptionalLongArg(optionalLongArg); |
| + v8SetReturnValueString(info, result, info.GetIsolate()); |
| } |
| static void stringMethodOptionalLongArgMethodCallback(const v8::FunctionCallbackInfo<v8::Value>& info) |
| @@ -7144,12 +7186,14 @@ static void testInterfaceEmptyMethodOptionalLongArgMethod(const v8::FunctionCall |
| v8::TryCatch block; |
| V8RethrowTryCatchScope rethrow(block); |
| if (UNLIKELY(info.Length() <= 0)) { |
| - v8SetReturnValue(info, impl->testInterfaceEmptyMethodOptionalLongArg()); |
| + RefPtr<TestInterfaceEmpty> result = impl->testInterfaceEmptyMethodOptionalLongArg(); |
| + v8SetReturnValue(info, result.release()); |
| return; |
| } |
| TONATIVE_VOID_EXCEPTIONSTATE_INTERNAL(optionalLongArg, toInt32(info[0], exceptionState), exceptionState); |
| } |
| - v8SetReturnValue(info, impl->testInterfaceEmptyMethodOptionalLongArg(optionalLongArg)); |
| + RefPtr<TestInterfaceEmpty> result = impl->testInterfaceEmptyMethodOptionalLongArg(optionalLongArg); |
| + v8SetReturnValue(info, result.release()); |
| } |
| static void testInterfaceEmptyMethodOptionalLongArgMethodCallback(const v8::FunctionCallbackInfo<v8::Value>& info) |
| @@ -7168,12 +7212,14 @@ static void longMethodOptionalLongArgMethod(const v8::FunctionCallbackInfo<v8::V |
| v8::TryCatch block; |
| V8RethrowTryCatchScope rethrow(block); |
| if (UNLIKELY(info.Length() <= 0)) { |
| - v8SetReturnValueInt(info, impl->longMethodOptionalLongArg()); |
| + int result = impl->longMethodOptionalLongArg(); |
| + v8SetReturnValueInt(info, result); |
| return; |
| } |
| TONATIVE_VOID_EXCEPTIONSTATE_INTERNAL(optionalLongArg, toInt32(info[0], exceptionState), exceptionState); |
| } |
| - v8SetReturnValueInt(info, impl->longMethodOptionalLongArg(optionalLongArg)); |
| + int result = impl->longMethodOptionalLongArg(optionalLongArg); |
| + v8SetReturnValueInt(info, result); |
| } |
| static void longMethodOptionalLongArgMethodCallback(const v8::FunctionCallbackInfo<v8::Value>& info) |
| @@ -9814,7 +9860,8 @@ static void partiallyRuntimeEnabledOverloadedVoidMethodMethodCallback(const v8:: |
| static void treatReturnedNullStringAsNullStringMethodMethod(const v8::FunctionCallbackInfo<v8::Value>& info) |
| { |
| TestObject* impl = V8TestObject::toNative(info.Holder()); |
| - v8SetReturnValueStringOrNull(info, impl->treatReturnedNullStringAsNullStringMethod(), info.GetIsolate()); |
| + String result = impl->treatReturnedNullStringAsNullStringMethod(); |
| + v8SetReturnValueStringOrNull(info, result, info.GetIsolate()); |
| } |
| static void treatReturnedNullStringAsNullStringMethodMethodCallback(const v8::FunctionCallbackInfo<v8::Value>& info) |
| @@ -9827,7 +9874,8 @@ static void treatReturnedNullStringAsNullStringMethodMethodCallback(const v8::Fu |
| static void treatReturnedNullStringAsUndefinedStringMethodMethod(const v8::FunctionCallbackInfo<v8::Value>& info) |
| { |
| TestObject* impl = V8TestObject::toNative(info.Holder()); |
| - v8SetReturnValueStringOrUndefined(info, impl->treatReturnedNullStringAsUndefinedStringMethod(), info.GetIsolate()); |
| + String result = impl->treatReturnedNullStringAsUndefinedStringMethod(); |
| + v8SetReturnValueStringOrUndefined(info, result, info.GetIsolate()); |
| } |
| static void treatReturnedNullStringAsUndefinedStringMethodMethodCallback(const v8::FunctionCallbackInfo<v8::Value>& info) |
| @@ -9840,7 +9888,8 @@ static void treatReturnedNullStringAsUndefinedStringMethodMethodCallback(const v |
| static void treatReturnedNullStringAsNullByteStringMethodMethod(const v8::FunctionCallbackInfo<v8::Value>& info) |
| { |
| TestObject* impl = V8TestObject::toNative(info.Holder()); |
| - v8SetReturnValueStringOrNull(info, impl->treatReturnedNullStringAsNullByteStringMethod(), info.GetIsolate()); |
| + String result = impl->treatReturnedNullStringAsNullByteStringMethod(); |
| + v8SetReturnValueStringOrNull(info, result, info.GetIsolate()); |
| } |
| static void treatReturnedNullStringAsNullByteStringMethodMethodCallback(const v8::FunctionCallbackInfo<v8::Value>& info) |
| @@ -9853,7 +9902,8 @@ static void treatReturnedNullStringAsNullByteStringMethodMethodCallback(const v8 |
| static void treatReturnedNullStringAsUndefinedByteStringMethodMethod(const v8::FunctionCallbackInfo<v8::Value>& info) |
| { |
| TestObject* impl = V8TestObject::toNative(info.Holder()); |
| - v8SetReturnValueStringOrUndefined(info, impl->treatReturnedNullStringAsUndefinedByteStringMethod(), info.GetIsolate()); |
| + String result = impl->treatReturnedNullStringAsUndefinedByteStringMethod(); |
| + v8SetReturnValueStringOrUndefined(info, result, info.GetIsolate()); |
| } |
| static void treatReturnedNullStringAsUndefinedByteStringMethodMethodCallback(const v8::FunctionCallbackInfo<v8::Value>& info) |
| @@ -9866,7 +9916,8 @@ static void treatReturnedNullStringAsUndefinedByteStringMethodMethodCallback(con |
| static void treatReturnedNullStringAsNullScalarValueStringMethodMethod(const v8::FunctionCallbackInfo<v8::Value>& info) |
| { |
| TestObject* impl = V8TestObject::toNative(info.Holder()); |
| - v8SetReturnValueStringOrNull(info, impl->treatReturnedNullStringAsNullScalarValueStringMethod(), info.GetIsolate()); |
| + String result = impl->treatReturnedNullStringAsNullScalarValueStringMethod(); |
| + v8SetReturnValueStringOrNull(info, result, info.GetIsolate()); |
| } |
| static void treatReturnedNullStringAsNullScalarValueStringMethodMethodCallback(const v8::FunctionCallbackInfo<v8::Value>& info) |
| @@ -9879,7 +9930,8 @@ static void treatReturnedNullStringAsNullScalarValueStringMethodMethodCallback(c |
| static void treatReturnedNullStringAsUndefinedScalarValueStringMethodMethod(const v8::FunctionCallbackInfo<v8::Value>& info) |
| { |
| TestObject* impl = V8TestObject::toNative(info.Holder()); |
| - v8SetReturnValueStringOrUndefined(info, impl->treatReturnedNullStringAsUndefinedScalarValueStringMethod(), info.GetIsolate()); |
| + String result = impl->treatReturnedNullStringAsUndefinedScalarValueStringMethod(); |
| + v8SetReturnValueStringOrUndefined(info, result, info.GetIsolate()); |
| } |
| static void treatReturnedNullStringAsUndefinedScalarValueStringMethodMethodCallback(const v8::FunctionCallbackInfo<v8::Value>& info) |
| @@ -10392,7 +10444,8 @@ static void nodeMethodWithVariousArgumentsImplementedInPrivateScriptMethodCallba |
| static void toStringMethod(const v8::FunctionCallbackInfo<v8::Value>& info) |
| { |
| TestObject* impl = V8TestObject::toNative(info.Holder()); |
| - v8SetReturnValueString(info, impl->stringifierAttribute(), info.GetIsolate()); |
| + String result = impl->stringifierAttribute(); |
| + v8SetReturnValueString(info, result, info.GetIsolate()); |
| } |
| static void toStringMethodCallback(const v8::FunctionCallbackInfo<v8::Value>& info) |