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

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

Issue 1008353002: bindings: Reduces the binary size by reducing # of callback functions. (Closed) Base URL: svn://svn.chromium.org/blink/trunk
Patch Set: Addressed review comments. Created 5 years, 9 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_attributes.py
diff --git a/Source/bindings/scripts/v8_attributes.py b/Source/bindings/scripts/v8_attributes.py
index 0b85ff8c7cd4b79f35b7f6f970c9e7fcd682ebe4..6401ac9a767fe84a89996bd70ccedc6329d3ba92 100644
--- a/Source/bindings/scripts/v8_attributes.py
+++ b/Source/bindings/scripts/v8_attributes.py
@@ -141,7 +141,7 @@ def attribute_context(interface, attribute):
}
if is_constructor_attribute(attribute):
- constructor_getter_context(interface, attribute, context)
+ update_constructor_attribute_context(interface, attribute, context)
if not has_custom_getter(attribute):
getter_context(interface, attribute, context)
if not has_custom_setter(attribute) and has_setter(attribute):
@@ -517,5 +517,6 @@ def is_constructor_attribute(attribute):
return attribute.idl_type.name.endswith('Constructor')
-def constructor_getter_context(interface, attribute, context):
+def update_constructor_attribute_context(interface, attribute, context):
context['needs_constructor_getter_callback'] = context['measure_as'] or context['deprecate_as']
+ context['needs_constructor_setter_callback'] = context['name'] != context['constructor_type']
haraken 2015/03/17 08:48:07 Can we add a comment and mention why we need to ch
Yuki 2015/03/17 09:10:05 Done.

Powered by Google App Engine
This is Rietveld 408576698