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

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

Issue 877523004: Add extended attribute, [Measure], to simplify use counting (Closed) Base URL: svn://svn.chromium.org/blink/trunk
Patch Set: Remove inheritance of [Measure] Created 5 years, 10 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
« no previous file with comments | « Source/bindings/scripts/v8_attributes.py ('k') | Source/bindings/scripts/v8_methods.py » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: Source/bindings/scripts/v8_interface.py
diff --git a/Source/bindings/scripts/v8_interface.py b/Source/bindings/scripts/v8_interface.py
index cf852f4efc5825e0fa5d5e3b287b00fa585b1bfa..2670bbc944363032680c6413f7e57db27c5dfd71 100644
--- a/Source/bindings/scripts/v8_interface.py
+++ b/Source/bindings/scripts/v8_interface.py
@@ -193,7 +193,7 @@ def interface_context(interface):
is_active_dom_object or
is_dependent_lifetime)
else 'Independent',
- 'measure_as': v8_utilities.measure_as(interface), # [MeasureAs]
+ 'measure_as': v8_utilities.measure_as(interface, None), # [MeasureAs]
'parent_interface': parent_interface,
'pass_cpp_type': cpp_template_type(
cpp_ptr_type('PassRefPtr', 'RawPtr', this_gc_type),
@@ -255,7 +255,7 @@ def interface_context(interface):
'named_constructor': named_constructor,
})
- constants = [constant_context(constant) for constant in interface.constants]
+ constants = [constant_context(constant, interface) for constant in interface.constants]
special_getter_constants = []
runtime_enabled_constants = []
@@ -564,13 +564,13 @@ def interface_context(interface):
# [DeprecateAs], [Reflect], [RuntimeEnabled]
-def constant_context(constant):
+def constant_context(constant, interface):
extended_attributes = constant.extended_attributes
return {
'cpp_class': extended_attributes.get('PartialInterfaceImplementedAs'),
'deprecate_as': v8_utilities.deprecate_as(constant), # [DeprecateAs]
'idl_type': constant.idl_type.name,
- 'measure_as': v8_utilities.measure_as(constant), # [MeasureAs]
+ 'measure_as': v8_utilities.measure_as(constant, interface), # [MeasureAs]
'name': constant.name,
# FIXME: use 'reflected_name' as correct 'name'
'reflected_name': extended_attributes.get('Reflect', constant.name),
« no previous file with comments | « Source/bindings/scripts/v8_attributes.py ('k') | Source/bindings/scripts/v8_methods.py » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698