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

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

Issue 139653005: IDL compiler: sync Python to r166626 (Closed) Base URL: svn://svn.chromium.org/blink/trunk
Patch Set: Refactored Created 6 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 | « no previous file | Source/bindings/templates/interface.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
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 ab9e32a39f596009ba3c030278b45b323e890aea..e160e66aaf7bb8c17af0941d3aa1ddda05045326 100644
--- a/Source/bindings/scripts/unstable/v8_interface.py
+++ b/Source/bindings/scripts/unstable/v8_interface.py
@@ -88,17 +88,20 @@ def generate_interface(interface):
if is_check_security:
includes.add('bindings/v8/BindingSecurity.h')
- # [SetWrapperReferenceFrom]
- reachable_node_function = extended_attributes.get('SetWrapperReferenceFrom')
- if reachable_node_function:
- includes.update(['bindings/v8/V8GCController.h',
- 'core/dom/Element.h'])
+ # [GarbageCollected]
+ is_garbage_collected = 'GarbageCollected' in extended_attributes
# [MeasureAs]
is_measure_as = 'MeasureAs' in extended_attributes
if is_measure_as:
includes.add('core/frame/UseCounter.h')
+ # [SetWrapperReferenceFrom]
+ reachable_node_function = extended_attributes.get('SetWrapperReferenceFrom')
+ if reachable_node_function:
+ includes.update(['bindings/v8/V8GCController.h',
+ 'core/dom/Element.h'])
+
# [SetWrapperReferenceTo]
set_wrapper_reference_to_list = [{
'name': argument.name,
@@ -135,11 +138,14 @@ def generate_interface(interface):
'is_document': is_document,
'is_event_target': inherits_interface(interface.name, 'EventTarget'),
'is_exception': interface.is_exception,
- 'is_garbage_collected': 'GarbageCollected' in extended_attributes, # [GarbageCollected]
+ 'is_garbage_collected': is_garbage_collected,
'is_node': inherits_interface(interface.name, 'Node'),
'measure_as': v8_utilities.measure_as(interface), # [MeasureAs]
'parent_interface': parent_interface,
+ 'pass_ref_ptr': 'PassRefPtrWillBeRawPtr' if is_garbage_collected else
+ 'PassRefPtr',
'reachable_node_function': reachable_node_function,
+ 'ref_ptr': 'RefPtrWillBeRawPtr' if is_garbage_collected else 'RefPtr',
'runtime_enabled_function': runtime_enabled_function_name(interface), # [RuntimeEnabled]
'set_wrapper_reference_to_list': set_wrapper_reference_to_list,
'special_wrap_for': special_wrap_for,
« no previous file with comments | « no previous file | Source/bindings/templates/interface.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698