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

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

Issue 36793003: IDL compiler: constructor attributes (Closed) Base URL: svn://svn.chromium.org/blink/trunk
Patch Set: Rebased Created 7 years, 2 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/unstable/v8_attributes.py ('k') | Source/bindings/scripts/unstable/v8_utilities.py » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: Source/bindings/scripts/unstable/v8_types.py
diff --git a/Source/bindings/scripts/unstable/v8_types.py b/Source/bindings/scripts/unstable/v8_types.py
index 8de21fc752f63af6d4739cbe1a9d425846e5a643..ae0df084ef28e73970e41fa492fbb0686b8ae2bc 100644
--- a/Source/bindings/scripts/unstable/v8_types.py
+++ b/Source/bindings/scripts/unstable/v8_types.py
@@ -43,6 +43,7 @@ import re
from v8_globals import includes
import idl_definitions # for UnionType
+from v8_utilities import strip_suffix
################################################################################
# IDL types
@@ -184,6 +185,10 @@ TYPED_ARRAYS = {
}
+def constructor_type(idl_type):
+ return strip_suffix(idl_type, 'Constructor')
+
+
def is_dom_node_type(idl_type):
return (idl_type in DOM_NODE_TYPES or
(idl_type.startswith(('HTML', 'SVG')) and
@@ -320,6 +325,8 @@ def includes_for_type(idl_type):
this_array_or_sequence_type = array_or_sequence_type(idl_type)
if this_array_or_sequence_type:
return includes_for_type(this_array_or_sequence_type)
+ if idl_type.endswith('Constructor'):
+ idl_type = constructor_type(idl_type)
return set(['V8%s.h' % idl_type])
« no previous file with comments | « Source/bindings/scripts/unstable/v8_attributes.py ('k') | Source/bindings/scripts/unstable/v8_utilities.py » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698