| Index: third_party/WebKit/Source/bindings/templates/interface_base.cpp
|
| diff --git a/third_party/WebKit/Source/bindings/templates/interface_base.cpp b/third_party/WebKit/Source/bindings/templates/interface_base.cpp
|
| index 3f4e4511ea482a2666ffa5ce84cb8c764a8e155b..9716125107801ce15d1b788bd74c28fc4bd5b021 100644
|
| --- a/third_party/WebKit/Source/bindings/templates/interface_base.cpp
|
| +++ b/third_party/WebKit/Source/bindings/templates/interface_base.cpp
|
| @@ -472,6 +472,13 @@ static void install{{v8_class}}Template(v8::Local<v8::FunctionTemplate> function
|
| functionTemplate->SetHiddenPrototype(true);
|
| {% endif %}
|
|
|
| + {# Willful violation of WebIDL 4.5.4 and 4.7 - implement the class string
|
| + for interfaces via @@toStringTag on the prototype. WebIDL requires
|
| + @@toStringTag instances and prototype (with 'Prototype' appended) but
|
| + this has performance concerns and may not be necessary for web compat.
|
| + https://www.w3.org/Bugs/Public/show_bug.cgi?id=28244 #}
|
| + prototypeTemplate->Set(v8::Symbol::GetToStringTag(isolate), v8AtomicString(isolate, "{{interface_name}}"));
|
| +
|
| // Custom toString template
|
| functionTemplate->Set(v8AtomicString(isolate, "toString"), V8PerIsolateData::from(isolate)->toStringTemplate());
|
| {% endif %}
|
|
|