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

Unified Diff: third_party/WebKit/Source/bindings/templates/union_container.cpp.tmpl

Issue 2810843002: bindings: Make the sequence conversion code more complaint with WebIDL. (Closed)
Patch Set: Created 3 years, 8 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/templates/union_container.cpp.tmpl
diff --git a/third_party/WebKit/Source/bindings/templates/union_container.cpp.tmpl b/third_party/WebKit/Source/bindings/templates/union_container.cpp.tmpl
index 02dca6c3f7a36d1120bf1cef5a09f73db0a84fe0..118a9c2fecdc2c8d43bedee68b81ffad8b4a1c7c 100644
--- a/third_party/WebKit/Source/bindings/templates/union_container.cpp.tmpl
+++ b/third_party/WebKit/Source/bindings/templates/union_container.cpp.tmpl
@@ -99,10 +99,7 @@ void {{v8_class}}::toImpl(v8::Isolate* isolate, v8::Local<v8::Value> v8Value, {{
{% endif %}
{% if array_or_sequence_type %}
{# 11.1, 11.2. Arrays and Sequences #}
- {# FIXME: This should also check "object but not RegExp". Add checks
- when we implement conversions for Date and RegExp. #}
- {# TODO(bashi): Should check @@iterator symbol instead. #}
- if (v8Value->IsArray()) {
+ if (IsV8Sequence(v8Value, isolate, exceptionState)) {
{{v8_value_to_local_cpp_value(array_or_sequence_type) | indent}}
impl.set{{array_or_sequence_type.type_name}}(cppValue);
return;

Powered by Google App Engine
This is Rietveld 408576698