Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(311)

Unified Diff: third_party/WebKit/Source/bindings/tests/results/core/V8TestDictionaryDerived.cpp

Issue 2340883003: Treat null dictionary members as missing per WebIDL (Closed)
Patch Set: Created 4 years, 3 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
Index: third_party/WebKit/Source/bindings/tests/results/core/V8TestDictionaryDerived.cpp
diff --git a/third_party/WebKit/Source/bindings/tests/results/core/V8TestDictionaryDerived.cpp b/third_party/WebKit/Source/bindings/tests/results/core/V8TestDictionaryDerived.cpp
index d44ed6feb3bf9e0a0a0994540771363f1e16354d..2941ba3e54c25e87c053e53273920134ae16d0fd 100644
--- a/third_party/WebKit/Source/bindings/tests/results/core/V8TestDictionaryDerived.cpp
+++ b/third_party/WebKit/Source/bindings/tests/results/core/V8TestDictionaryDerived.cpp
@@ -37,7 +37,7 @@ void V8TestDictionaryDerivedImplementedAs::toImpl(v8::Isolate* isolate, v8::Loca
exceptionState.rethrowV8Exception(block.Exception());
return;
}
- if (derivedStringMemberValue.IsEmpty() || derivedStringMemberValue->IsUndefined()) {
+ if (isUndefinedOrNull(derivedStringMemberValue)) {
// Do nothing.
} else {
V8StringResource<> derivedStringMember = derivedStringMemberValue;
@@ -51,7 +51,7 @@ void V8TestDictionaryDerivedImplementedAs::toImpl(v8::Isolate* isolate, v8::Loca
exceptionState.rethrowV8Exception(block.Exception());
return;
}
- if (derivedStringMemberWithDefaultValue.IsEmpty() || derivedStringMemberWithDefaultValue->IsUndefined()) {
+ if (isUndefinedOrNull(derivedStringMemberWithDefaultValue)) {
// Do nothing.
} else {
V8StringResource<> derivedStringMemberWithDefault = derivedStringMemberWithDefaultValue;
@@ -65,7 +65,7 @@ void V8TestDictionaryDerivedImplementedAs::toImpl(v8::Isolate* isolate, v8::Loca
exceptionState.rethrowV8Exception(block.Exception());
return;
}
- if (requiredLongMemberValue.IsEmpty() || requiredLongMemberValue->IsUndefined()) {
+ if (isUndefinedOrNull(requiredLongMemberValue)) {
exceptionState.throwTypeError("required member requiredLongMember is undefined.");
return;
} else {
@@ -80,7 +80,7 @@ void V8TestDictionaryDerivedImplementedAs::toImpl(v8::Isolate* isolate, v8::Loca
exceptionState.rethrowV8Exception(block.Exception());
return;
}
- if (stringOrDoubleSequenceMemberValue.IsEmpty() || stringOrDoubleSequenceMemberValue->IsUndefined()) {
+ if (isUndefinedOrNull(stringOrDoubleSequenceMemberValue)) {
// Do nothing.
} else {
HeapVector<StringOrDouble> stringOrDoubleSequenceMember = toImplArray<HeapVector<StringOrDouble>>(stringOrDoubleSequenceMemberValue, 0, isolate, exceptionState);

Powered by Google App Engine
This is Rietveld 408576698