| Index: Source/bindings/tests/results/core/V8TestTypedefs.cpp
|
| diff --git a/Source/bindings/tests/results/core/V8TestTypedefs.cpp b/Source/bindings/tests/results/core/V8TestTypedefs.cpp
|
| index 6bebcf28f30bf125c2dfbac2fb19ee847e66cf96..d569013ec6f225c6cd4b995db656f76030f927cf 100644
|
| --- a/Source/bindings/tests/results/core/V8TestTypedefs.cpp
|
| +++ b/Source/bindings/tests/results/core/V8TestTypedefs.cpp
|
| @@ -8,6 +8,7 @@
|
| #include "V8TestTypedefs.h"
|
|
|
| #include "bindings/core/v8/ExceptionState.h"
|
| +#include "bindings/core/v8/UnionTypesCore.h"
|
| #include "bindings/core/v8/V8DOMConfiguration.h"
|
| #include "bindings/core/v8/V8HiddenValue.h"
|
| #include "bindings/core/v8/V8ObjectConstructor.h"
|
| @@ -182,15 +183,14 @@ static void uLongLongMethodTestInterfaceEmptyTypeSequenceArgMethodCallback(const
|
| static void testInterfaceOrTestInterfaceEmptyMethodMethod(const v8::FunctionCallbackInfo<v8::Value>& info)
|
| {
|
| TestTypedefs* impl = V8TestTypedefs::toImpl(info.Holder());
|
| - RefPtr<TestInterfaceImplementation> result0 = nullptr;
|
| - RefPtr<TestInterfaceEmpty> result1 = nullptr;
|
| - impl->testInterfaceOrTestInterfaceEmptyMethod(result0, result1);
|
| - if (result0) {
|
| - v8SetReturnValue(info, result0.release());
|
| + TestInterfaceOrTestInterfaceEmpty result;
|
| + impl->testInterfaceOrTestInterfaceEmptyMethod(result);
|
| + if (result.isTestInterface()) {
|
| + v8SetReturnValue(info, result.getAsTestInterface());
|
| return;
|
| }
|
| - if (result1) {
|
| - v8SetReturnValue(info, result1.release());
|
| + if (result.isTestInterfaceEmpty()) {
|
| + v8SetReturnValue(info, result.getAsTestInterfaceEmpty());
|
| return;
|
| }
|
| v8SetReturnValueNull(info);
|
| @@ -206,15 +206,14 @@ static void testInterfaceOrTestInterfaceEmptyMethodMethodCallback(const v8::Func
|
| static void domStringOrDoubleMethodMethod(const v8::FunctionCallbackInfo<v8::Value>& info)
|
| {
|
| TestTypedefs* impl = V8TestTypedefs::toImpl(info.Holder());
|
| - String result0;
|
| - Nullable<double> result1;
|
| - impl->domStringOrDoubleMethod(result0, result1);
|
| - if (!result0.isNull()) {
|
| - v8SetReturnValueString(info, result0, info.GetIsolate());
|
| + StringOrDouble result;
|
| + impl->domStringOrDoubleMethod(result);
|
| + if (result.isString()) {
|
| + v8SetReturnValueString(info, result.getAsString(), info.GetIsolate());
|
| return;
|
| }
|
| - if (result1) {
|
| - v8SetReturnValue(info, result1.get());
|
| + if (result.isDouble()) {
|
| + v8SetReturnValue(info, result.getAsDouble());
|
| return;
|
| }
|
| v8SetReturnValueNull(info);
|
|
|