| Index: Source/bindings/tests/results/core/V8TestSpecialOperations.cpp
|
| diff --git a/Source/bindings/tests/results/core/V8TestSpecialOperations.cpp b/Source/bindings/tests/results/core/V8TestSpecialOperations.cpp
|
| index 55f9547da03efb469f420bdd6ae0a8ede2ac1746..b039ac49c66f0f0dc8bdf109628ba0c6ad1f039d 100644
|
| --- a/Source/bindings/tests/results/core/V8TestSpecialOperations.cpp
|
| +++ b/Source/bindings/tests/results/core/V8TestSpecialOperations.cpp
|
| @@ -8,6 +8,7 @@
|
| #include "V8TestSpecialOperations.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/V8Node.h"
|
| @@ -46,15 +47,14 @@ static void namedItemMethod(const v8::FunctionCallbackInfo<v8::Value>& info)
|
| {
|
| TOSTRING_VOID_INTERNAL(name, info[0]);
|
| }
|
| - RefPtrWillBeRawPtr<Node> result0 = nullptr;
|
| - RefPtrWillBeRawPtr<NodeList> result1 = nullptr;
|
| - impl->getItem(name, result0, result1);
|
| - if (result0) {
|
| - v8SetReturnValue(info, result0.release());
|
| + NodeOrNodeList result;
|
| + impl->getItem(name, result);
|
| + if (result.isNode()) {
|
| + v8SetReturnValue(info, result.getAsNode());
|
| return;
|
| }
|
| - if (result1) {
|
| - v8SetReturnValue(info, result1.release());
|
| + if (result.isNodeList()) {
|
| + v8SetReturnValue(info, result.getAsNodeList());
|
| return;
|
| }
|
| v8SetReturnValueNull(info);
|
| @@ -71,17 +71,16 @@ static void namedPropertyGetter(v8::Local<v8::String> name, const v8::PropertyCa
|
| {
|
| TestSpecialOperations* impl = V8TestSpecialOperations::toImpl(info.Holder());
|
| AtomicString propertyName = toCoreAtomicString(name);
|
| - RefPtrWillBeRawPtr<Node> result0 = nullptr;
|
| - RefPtrWillBeRawPtr<NodeList> result1 = nullptr;
|
| - impl->getItem(propertyName, result0, result1);
|
| - if (!(result0 || result1))
|
| + NodeOrNodeList result;
|
| + impl->getItem(propertyName, result);
|
| + if (result.isNull())
|
| return;
|
| - if (result0) {
|
| - v8SetReturnValue(info, result0.release());
|
| + if (result.isNode()) {
|
| + v8SetReturnValue(info, result.getAsNode());
|
| return;
|
| }
|
| - if (result1) {
|
| - v8SetReturnValue(info, result1.release());
|
| + if (result.isNodeList()) {
|
| + v8SetReturnValue(info, result.getAsNodeList());
|
| return;
|
| }
|
| ASSERT_NOT_REACHED();
|
|
|