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

Unified Diff: bindings/scripts/v8_attributes.py

Issue 959933002: Move IDLs to 39 roll (Closed) Base URL: https://dart.googlecode.com/svn/third_party/WebCore
Patch Set: 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 | « bindings/scripts/utilities.py ('k') | bindings/scripts/v8_dictionary.py » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: bindings/scripts/v8_attributes.py
diff --git a/bindings/scripts/v8_attributes.py b/bindings/scripts/v8_attributes.py
index bb61ef9c648598eea08c526ff3041e1baf71216d..2a09c887198a13d4a0a4151b2e20a10345bec385 100644
--- a/bindings/scripts/v8_attributes.py
+++ b/bindings/scripts/v8_attributes.py
@@ -38,7 +38,9 @@ from idl_types import inherits_interface
from v8_globals import includes, interfaces
import v8_types
import v8_utilities
-from v8_utilities import capitalize, cpp_name, has_extended_attribute, has_extended_attribute_value, scoped_name, strip_suffix, uncapitalize
+from v8_utilities import (capitalize, cpp_name, has_extended_attribute,
+ has_extended_attribute_value, scoped_name, strip_suffix,
+ uncapitalize, extended_attribute_value_as_list)
def attribute_context(interface, attribute):
@@ -56,7 +58,7 @@ def attribute_context(interface, attribute):
is_custom_element_callbacks = 'CustomElementCallbacks' in extended_attributes
is_reflect = 'Reflect' in extended_attributes
if is_custom_element_callbacks or is_reflect:
- includes.add('core/dom/custom/CustomElementCallbackDispatcher.h')
+ includes.add('core/dom/custom/CustomElementProcessingStack.h')
# [PerWorldBindings]
if 'PerWorldBindings' in extended_attributes:
assert idl_type.is_wrapper_type or 'LogActivity' in extended_attributes, '[PerWorldBindings] should only be used with wrapper types: %s.%s' % (interface.name, attribute.name)
@@ -84,7 +86,6 @@ def attribute_context(interface, attribute):
'access_control_list': access_control_list(attribute),
'activity_logging_world_list_for_getter': v8_utilities.activity_logging_world_list(attribute, 'Getter'), # [ActivityLogging]
'activity_logging_world_list_for_setter': v8_utilities.activity_logging_world_list(attribute, 'Setter'), # [ActivityLogging]
- 'activity_logging_include_old_value_for_setter': 'LogPreviousValue' in extended_attributes, # [ActivityLogging]
'activity_logging_world_check': v8_utilities.activity_logging_world_check(attribute), # [ActivityLogging]
'argument_cpp_type': idl_type.cpp_type_args(used_as_rvalue_type=True),
'cached_attribute_validation_method': extended_attributes.get('CachedAttribute'),
@@ -135,8 +136,7 @@ def attribute_context(interface, attribute):
'reflect_empty': extended_attributes.get('ReflectEmpty'),
'reflect_invalid': extended_attributes.get('ReflectInvalid', ''),
'reflect_missing': extended_attributes.get('ReflectMissing'),
- 'reflect_only': extended_attributes['ReflectOnly'].split('|')
- if 'ReflectOnly' in extended_attributes else None,
+ 'reflect_only': extended_attribute_value_as_list(attribute, 'ReflectOnly'),
'runtime_enabled_function': v8_utilities.runtime_enabled_function_name(attribute), # [RuntimeEnabled]
'setter_callback': setter_callback_name(interface, attribute),
'should_be_exposed_to_script': not (is_implemented_in_private_script and is_only_exposed_to_private_script),
@@ -176,7 +176,8 @@ def getter_context(interface, attribute, context):
release = False
if 'ImplementedInPrivateScript' in extended_attributes:
if (not idl_type.is_wrapper_type and
- not idl_type.is_basic_type):
+ not idl_type.is_basic_type and
+ not idl_type.is_enum):
raise Exception('Private scripts supports only primitive types and DOM wrappers.')
context['cpp_value_original'] = cpp_value
@@ -187,7 +188,6 @@ def getter_context(interface, attribute, context):
elif (idl_type.is_explicit_nullable or
base_idl_type == 'EventHandler' or
'CachedAttribute' in extended_attributes or
- 'LogPreviousValue' in extended_attributes or
'ReflectOnly' in extended_attributes or
context['is_keep_alive_for_gc'] or
context['is_getter_raises_exception']):
@@ -327,7 +327,7 @@ def setter_context(interface, attribute, context):
'has_setter_exception_state':
is_setter_raises_exception or has_type_checking_interface or
context['has_type_checking_unrestricted'] or
- idl_type.may_raise_exception_on_conversion,
+ idl_type.v8_conversion_needs_exception_state,
'has_type_checking_interface': has_type_checking_interface,
'is_setter_call_with_execution_context': v8_utilities.has_extended_attribute_value(
attribute, 'SetterCallWith', 'ExecutionContext'),
« no previous file with comments | « bindings/scripts/utilities.py ('k') | bindings/scripts/v8_dictionary.py » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698