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

Unified Diff: Source/bindings/templates/methods.cpp

Issue 419673003: IDL: Remove UNLIKELY() from constructor (Closed) Base URL: https://chromium.googlesource.com/chromium/blink.git@master
Patch Set: Created 6 years, 5 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 | « no previous file | Source/bindings/tests/results/V8TestInterfaceConstructor.cpp » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: Source/bindings/templates/methods.cpp
diff --git a/Source/bindings/templates/methods.cpp b/Source/bindings/templates/methods.cpp
index 81f925078718e57f48a221dbcb0b7b9c37cb5ffa..4e5eed4988e95acdb2d0073c444d2cdac3486994 100644
--- a/Source/bindings/templates/methods.cpp
+++ b/Source/bindings/templates/methods.cpp
@@ -435,8 +435,6 @@ static void {{method.name}}MethodCallback{{world_suffix}}(const v8::FunctionCall
{% else %}
if (contextData && contextData->activityLogger()) {
{% endif %}
- {# FIXME: replace toVectorOfArguments with toNativeArguments(info, 0)
- and delete toVectorOfArguments #}
Vector<v8::Handle<v8::Value> > loggerArgs = toNativeArguments<v8::Handle<v8::Value> >(info, 0);
contextData->activityLogger()->logMethod("{{interface_name}}.{{method.name}}", info.Length(), loggerArgs.data());
}
@@ -575,8 +573,7 @@ static void {{name}}(const v8::FunctionCallbackInfo<v8::Value>& info)
{% endif %}
{# Overloaded constructors have length checked during overload resolution #}
{% if constructor.number_of_required_arguments and not constructor.overload_index %}
- {# FIXME: remove UNLIKELY: constructors are expensive, so no difference. #}
- if (UNLIKELY(info.Length() < {{constructor.number_of_required_arguments}})) {
+ if (info.Length() < {{constructor.number_of_required_arguments}}) {
{{throw_minimum_arity_type_error(constructor, constructor.number_of_required_arguments)}};
return;
}
« no previous file with comments | « no previous file | Source/bindings/tests/results/V8TestInterfaceConstructor.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698