Index: third_party/WebKit/Source/bindings/scripts/v8_attributes.py |
diff --git a/third_party/WebKit/Source/bindings/scripts/v8_attributes.py b/third_party/WebKit/Source/bindings/scripts/v8_attributes.py |
index 6535851e61147d90645e281a66d205d8ea6f9f08..5cb1c1f037761971ebc1b7bb2ebd425fc2ee2dae 100644 |
--- a/third_party/WebKit/Source/bindings/scripts/v8_attributes.py |
+++ b/third_party/WebKit/Source/bindings/scripts/v8_attributes.py |
@@ -50,7 +50,7 @@ def attribute_context(interface, attribute): |
extended_attributes = attribute.extended_attributes |
idl_type.add_includes_for_type(extended_attributes) |
- if idl_type.enum_values: |
+ if idl_type.enum_values or v8_utilities.api_experiment_name(attribute): |
includes.add('core/inspector/ConsoleMessage.h') |
# [CheckSecurity] |
@@ -109,6 +109,7 @@ def attribute_context(interface, attribute): |
'deprecate_as': v8_utilities.deprecate_as(attribute), # [DeprecateAs] |
'enum_type': idl_type.enum_type, |
'enum_values': idl_type.enum_values, |
+ 'api_experiment_name': v8_utilities.api_experiment_name(attribute), # [APIExperimentEnabled] |
'exposed_test': v8_utilities.exposed(attribute, interface), # [Exposed] |
'has_custom_getter': has_custom_getter(attribute), |
'has_custom_setter': has_custom_setter(attribute), |
@@ -505,7 +506,7 @@ def is_constructor_attribute(attribute): |
def update_constructor_attribute_context(interface, attribute, context): |
- context['needs_constructor_getter_callback'] = context['measure_as'] or context['deprecate_as'] |
+ context['needs_constructor_getter_callback'] = context['measure_as'] or context['deprecate_as'] or context['api_experiment_name'] |
# When the attribute name is the same as the interface name, do not generate |
# callback functions for each attribute and use |
# {{cpp_class}}ConstructorAttributeSetterCallback. Otherwise, generate |