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

Unified Diff: Source/bindings/scripts/v8_types.py

Issue 1221743002: Teach Blink's IDL parser to handle defaulted sequences of strings. (Closed) Base URL: https://chromium.googlesource.com/chromium/blink.git@pinned
Patch Set: Add a test to LayoutTests/fast/dom/idl-dictionary-unittest.html Created 5 years, 6 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: Source/bindings/scripts/v8_types.py
diff --git a/Source/bindings/scripts/v8_types.py b/Source/bindings/scripts/v8_types.py
index d1dfb9f631a1193524bea2d4f4caad99f6b3f729..3272b297cb642adae4f0699e642618d43089b31b 100644
--- a/Source/bindings/scripts/v8_types.py
+++ b/Source/bindings/scripts/v8_types.py
@@ -938,12 +938,7 @@ def union_literal_cpp_value(idl_type, idl_literal):
def array_or_sequence_literal_cpp_value(idl_type, idl_literal):
# Only support empty arrays.
if idl_literal.value == '[]':
- element_type = idl_type.element_type
- ref_ptr_type = cpp_ptr_type('RefPtr', 'Member', element_type.gc_type)
- inner_type = cpp_template_type(ref_ptr_type, element_type.name)
- vector_type = cpp_ptr_type('Vector', 'HeapVector',
- element_type.gc_type)
- return cpp_template_type(vector_type, inner_type) + '()'
+ return cpp_type(idl_type) + '()'
raise ValueError('Unsupported literal type: ' + idl_literal.idl_type)
« no previous file with comments | « LayoutTests/fast/dom/idl-dictionary-unittest-expected.txt ('k') | Source/bindings/tests/idls/core/TestDictionary.idl » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698