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

Side by Side Diff: Source/bindings/templates/interface.cpp

Issue 331783003: Correct comment in bindings template (Closed) Base URL: svn://svn.chromium.org/blink/trunk
Patch Set: Better comment Created 6 years, 6 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 | « no previous file | no next file » | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 {% extends 'interface_base.cpp' %} 1 {% extends 'interface_base.cpp' %}
2 2
3 3
4 {##############################################################################} 4 {##############################################################################}
5 {% macro attribute_configuration(attribute) %} 5 {% macro attribute_configuration(attribute) %}
6 {% set getter_callback = 6 {% set getter_callback =
7 '%sV8Internal::%sAttributeGetterCallback' % 7 '%sV8Internal::%sAttributeGetterCallback' %
8 (cpp_class, attribute.name) 8 (cpp_class, attribute.name)
9 if not attribute.constructor_type else 9 if not attribute.constructor_type else
10 ('%sV8Internal::%sConstructorGetterCallback' % 10 ('%sV8Internal::%sConstructorGetterCallback' %
(...skipping 875 matching lines...) Expand 10 before | Expand all | Expand 10 after
886 'V8%s::domTemplate(isolate)' % parent_interface 886 'V8%s::domTemplate(isolate)' % parent_interface
887 if parent_interface else 'v8::Local<v8::FunctionTemplate>()' %} 887 if parent_interface else 'v8::Local<v8::FunctionTemplate>()' %}
888 {% if runtime_enabled_function %} 888 {% if runtime_enabled_function %}
889 if (!{{runtime_enabled_function}}()) 889 if (!{{runtime_enabled_function}}())
890 defaultSignature = V8DOMConfiguration::installDOMClassTemplate(functionT emplate, "", {{parent_template}}, {{v8_class}}::internalFieldCount, 0, 0, 0, 0, 0, 0, isolate); 890 defaultSignature = V8DOMConfiguration::installDOMClassTemplate(functionT emplate, "", {{parent_template}}, {{v8_class}}::internalFieldCount, 0, 0, 0, 0, 0, 0, isolate);
891 else 891 else
892 {% endif %} 892 {% endif %}
893 {% set runtime_enabled_indent = 4 if runtime_enabled_function else 0 %} 893 {% set runtime_enabled_indent = 4 if runtime_enabled_function else 0 %}
894 {% filter indent(runtime_enabled_indent, true) %} 894 {% filter indent(runtime_enabled_indent, true) %}
895 defaultSignature = V8DOMConfiguration::installDOMClassTemplate(functionTempl ate, "{{interface_name}}", {{parent_template}}, {{v8_class}}::internalFieldCount , 895 defaultSignature = V8DOMConfiguration::installDOMClassTemplate(functionTempl ate, "{{interface_name}}", {{parent_template}}, {{v8_class}}::internalFieldCount ,
896 {# Test needed as size 0 constant arrays are not allowed in VC++ #} 896 {# Test needed as size 0 arrays definitions are not allowed per standard
897 (so objects have distinct addresses), which is enforced by MSVC.
898 8.5.1 Aggregates [dcl.init.aggr]
899 An array of unknown size initialized with a brace-enclosed
900 initializer-list containing n initializer-clauses, where n shall be
901 greater than zero, is defined as having n elements (8.3.4). #}
897 {% set attributes_name, attributes_length = 902 {% set attributes_name, attributes_length =
898 ('%sAttributes' % v8_class, 903 ('%sAttributes' % v8_class,
899 'WTF_ARRAY_LENGTH(%sAttributes)' % v8_class) 904 'WTF_ARRAY_LENGTH(%sAttributes)' % v8_class)
900 if has_attribute_configuration else (0, 0) %} 905 if has_attribute_configuration else (0, 0) %}
901 {% set accessors_name, accessors_length = 906 {% set accessors_name, accessors_length =
902 ('%sAccessors' % v8_class, 907 ('%sAccessors' % v8_class,
903 'WTF_ARRAY_LENGTH(%sAccessors)' % v8_class) 908 'WTF_ARRAY_LENGTH(%sAccessors)' % v8_class)
904 if has_accessors else (0, 0) %} 909 if has_accessors else (0, 0) %}
905 {% set methods_name, methods_length = 910 {% set methods_name, methods_length =
906 ('%sMethods' % v8_class, 911 ('%sMethods' % v8_class,
(...skipping 428 matching lines...) Expand 10 before | Expand all | Expand 10 after
1335 {% endif %} 1340 {% endif %}
1336 } 1341 }
1337 1342
1338 template<> 1343 template<>
1339 v8::Handle<v8::Value> toV8NoInline({{cpp_class}}* impl, v8::Handle<v8::Object> c reationContext, v8::Isolate* isolate) 1344 v8::Handle<v8::Value> toV8NoInline({{cpp_class}}* impl, v8::Handle<v8::Object> c reationContext, v8::Isolate* isolate)
1340 { 1345 {
1341 return toV8(impl, creationContext, isolate); 1346 return toV8(impl, creationContext, isolate);
1342 } 1347 }
1343 1348
1344 {% endblock %} 1349 {% endblock %}
OLDNEW
« no previous file with comments | « no previous file | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698