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 1118993002: Oilpan: IDL union objects should be put in HeapVector (Closed) Base URL: svn://svn.chromium.org/blink/trunk
Patch Set: Created 5 years, 8 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/union.h » ('j') | Source/bindings/templates/union.h » ('J')
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: Source/bindings/scripts/v8_types.py
diff --git a/Source/bindings/scripts/v8_types.py b/Source/bindings/scripts/v8_types.py
index 5e8a45aad46f67fd4d5df1ced2e418bff463a361..179601fa04f07e6937d3f3be895acdcab4420d8a 100644
--- a/Source/bindings/scripts/v8_types.py
+++ b/Source/bindings/scripts/v8_types.py
@@ -310,7 +310,7 @@ IdlType.set_will_be_garbage_collected_types = classmethod(
def gc_type(idl_type):
- if idl_type.is_garbage_collected or idl_type.is_dictionary:
+ if idl_type.is_garbage_collected or idl_type.is_dictionary or idl_type.is_union_type:
haraken 2015/05/01 14:58:13 bashi-san@: Maybe would it make more sense to set
bashi 2015/05/07 23:59:23 Probably, but we might want to seek a better namin
return 'GarbageCollectedObject'
if idl_type.is_will_be_garbage_collected:
return 'WillBeGarbageCollectedObject'
@@ -322,7 +322,8 @@ IdlTypeBase.gc_type = property(gc_type)
def is_traceable(idl_type):
return (idl_type.is_garbage_collected
or idl_type.is_will_be_garbage_collected
- or idl_type.is_dictionary)
+ or idl_type.is_dictionary
+ or idl_type.is_union_type)
IdlTypeBase.is_traceable = property(is_traceable)
IdlUnionType.is_traceable = property(
@@ -590,7 +591,7 @@ def v8_value_to_cpp_value_array_or_sequence(native_array_element_type, v8_value,
this_cpp_type = None
ref_ptr_type = cpp_ptr_type('RefPtr', 'Member', native_array_element_type.gc_type)
expression_format = '(to{ref_ptr_type}NativeArray<{native_array_element_type}, V8{native_array_element_type}>({v8_value}, {index}, {isolate}, exceptionState))'
- elif native_array_element_type.is_dictionary:
+ elif native_array_element_type.is_dictionary or native_array_element_type.is_union_type:
ref_ptr_type = None
this_cpp_type = native_array_element_type.cpp_type
expression_format = 'toImplHeapArray<{cpp_type}>({v8_value}, {index}, {isolate}, exceptionState)'
« no previous file with comments | « no previous file | Source/bindings/templates/union.h » ('j') | Source/bindings/templates/union.h » ('J')

Powered by Google App Engine
This is Rietveld 408576698