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

Side by Side Diff: Source/bindings/scripts/v8_methods.py

Issue 877523004: Add extended attribute, [Measure], to simplify use counting (Closed) Base URL: svn://svn.chromium.org/blink/trunk
Patch Set: Remove inheritance of [Measure] Created 5 years, 9 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 unified diff | Download patch | Annotate | Revision Log
« no previous file with comments | « Source/bindings/scripts/v8_interface.py ('k') | Source/bindings/scripts/v8_utilities.py » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 # Copyright (C) 2013 Google Inc. All rights reserved. 1 # Copyright (C) 2013 Google Inc. All rights reserved.
2 # 2 #
3 # Redistribution and use in source and binary forms, with or without 3 # Redistribution and use in source and binary forms, with or without
4 # modification, are permitted provided that the following conditions are 4 # modification, are permitted provided that the following conditions are
5 # met: 5 # met:
6 # 6 #
7 # * Redistributions of source code must retain the above copyright 7 # * Redistributions of source code must retain the above copyright
8 # notice, this list of conditions and the following disclaimer. 8 # notice, this list of conditions and the following disclaimer.
9 # * Redistributions in binary form must reproduce the above 9 # * Redistributions in binary form must reproduce the above
10 # copyright notice, this list of conditions and the following disclaimer 10 # copyright notice, this list of conditions and the following disclaimer
(...skipping 145 matching lines...) Expand 10 before | Expand all | Expand 10 after
156 'is_do_not_check_signature': 'DoNotCheckSignature' in extended_attribute s, 156 'is_do_not_check_signature': 'DoNotCheckSignature' in extended_attribute s,
157 'is_explicit_nullable': idl_type.is_explicit_nullable, 157 'is_explicit_nullable': idl_type.is_explicit_nullable,
158 'is_implemented_in_private_script': is_implemented_in_private_script, 158 'is_implemented_in_private_script': is_implemented_in_private_script,
159 'is_partial_interface_member': 159 'is_partial_interface_member':
160 'PartialInterfaceImplementedAs' in extended_attributes, 160 'PartialInterfaceImplementedAs' in extended_attributes,
161 'is_per_world_bindings': 'PerWorldBindings' in extended_attributes, 161 'is_per_world_bindings': 'PerWorldBindings' in extended_attributes,
162 'is_raises_exception': is_raises_exception, 162 'is_raises_exception': is_raises_exception,
163 'is_read_only': is_unforgeable(interface, method), 163 'is_read_only': is_unforgeable(interface, method),
164 'is_static': is_static, 164 'is_static': is_static,
165 'is_variadic': arguments and arguments[-1].is_variadic, 165 'is_variadic': arguments and arguments[-1].is_variadic,
166 'measure_as': v8_utilities.measure_as(method), # [MeasureAs] 166 'measure_as': v8_utilities.measure_as(method, interface), # [MeasureAs]
167 'name': name, 167 'name': name,
168 'number_of_arguments': len(arguments), 168 'number_of_arguments': len(arguments),
169 'number_of_required_arguments': len([ 169 'number_of_required_arguments': len([
170 argument for argument in arguments 170 argument for argument in arguments
171 if not (argument.is_optional or argument.is_variadic)]), 171 if not (argument.is_optional or argument.is_variadic)]),
172 'number_of_required_or_variadic_arguments': len([ 172 'number_of_required_or_variadic_arguments': len([
173 argument for argument in arguments 173 argument for argument in arguments
174 if not argument.is_optional]), 174 if not argument.is_optional]),
175 'only_exposed_to_private_script': is_only_exposed_to_private_script, 175 'only_exposed_to_private_script': is_only_exposed_to_private_script,
176 'per_context_enabled_function': v8_utilities.per_context_enabled_functio n_name(method), # [PerContextEnabled] 176 'per_context_enabled_function': v8_utilities.per_context_enabled_functio n_name(method), # [PerContextEnabled]
(...skipping 270 matching lines...) Expand 10 before | Expand all | Expand 10 after
447 447
448 IdlOperation.returns_promise = property(method_returns_promise) 448 IdlOperation.returns_promise = property(method_returns_promise)
449 449
450 450
451 def argument_conversion_needs_exception_state(method, argument): 451 def argument_conversion_needs_exception_state(method, argument):
452 idl_type = argument.idl_type 452 idl_type = argument.idl_type
453 return (idl_type.v8_conversion_needs_exception_state or 453 return (idl_type.v8_conversion_needs_exception_state or
454 argument.is_variadic or 454 argument.is_variadic or
455 (method.returns_promise and (idl_type.is_string_type or 455 (method.returns_promise and (idl_type.is_string_type or
456 idl_type.is_enum))) 456 idl_type.is_enum)))
OLDNEW
« no previous file with comments | « Source/bindings/scripts/v8_interface.py ('k') | Source/bindings/scripts/v8_utilities.py » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698