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

Unified Diff: Source/bindings/scripts/unstable/v8_interface.py

Issue 110023002: IDL compiler: [InitializedByEventConstructor] attribute any (Closed) Base URL: svn://svn.chromium.org/blink/trunk
Patch Set: Rebased Created 7 years 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/unstable/v8_interface.py
diff --git a/Source/bindings/scripts/unstable/v8_interface.py b/Source/bindings/scripts/unstable/v8_interface.py
index 1e1c7ba3f59ec2d5e3aeec308191a35118c7c279..2c223e99359f6a9f7830b0e0a4b7423ace5c6d85 100644
--- a/Source/bindings/scripts/unstable/v8_interface.py
+++ b/Source/bindings/scripts/unstable/v8_interface.py
@@ -111,9 +111,14 @@ def generate_interface(interface):
# [EventConstructor]
has_event_constructor = 'EventConstructor' in extended_attributes
+ has_any_type_attributes = any(attribute
+ for attribute in interface.attributes
+ if attribute.idl_type == 'any')
if has_event_constructor:
includes.update(['bindings/v8/Dictionary.h',
'bindings/v8/V8ObjectConstructor.h'])
+ if has_any_type_attributes:
+ includes.add('bindings/v8/SerializedScriptValue.h')
template_contents = {
'conditional_string': conditional_string(interface), # [Conditional]
@@ -125,6 +130,7 @@ def generate_interface(interface):
'has_custom_to_v8': has_extended_attribute_value(interface, 'Custom', 'ToV8'), # [Custom=ToV8]
'has_custom_wrap': has_extended_attribute_value(interface, 'Custom', 'Wrap'), # [Custom=Wrap]
'has_event_constructor': has_event_constructor,
+ 'has_any_type_attributes': has_any_type_attributes,
'has_visit_dom_wrapper': (
# [Custom=Wrap], [GenerateVisitDOMWrapper]
has_extended_attribute_value(interface, 'Custom', 'VisitDOMWrapper') or

Powered by Google App Engine
This is Rietveld 408576698