Index: src/builtins/builtins.cc |
diff --git a/src/builtins/builtins.cc b/src/builtins/builtins.cc |
index b3cd1c653c880aeb8673d85cdb916b5089d54334..c84896ee007f942911e3a18b96637d516b36a8f3 100644 |
--- a/src/builtins/builtins.cc |
+++ b/src/builtins/builtins.cc |
@@ -116,6 +116,22 @@ Handle<Code> Builtins::OrdinaryToPrimitive(OrdinaryToPrimitiveHint hint) { |
} |
// static |
+int Builtins::GetBuiltinParameterCount(Isolate* isolate, Name name) { |
Igor Sheludko
2017/05/02 09:31:16
The |isolate| parameter can be removed.
|
+ switch (name) { |
+#define CASE(Name, ParamCount, ...) \ |
Igor Sheludko
2017/05/02 09:31:16
Please s/CASE/TFJ_CASE/ for better readability.
|
+ case k##Name: { \ |
+ return ParamCount; \ |
+ } |
+ BUILTIN_LIST(IGNORE_BUILTIN, IGNORE_BUILTIN, CASE, IGNORE_BUILTIN, |
+ IGNORE_BUILTIN, IGNORE_BUILTIN, IGNORE_BUILTIN, IGNORE_BUILTIN) |
+#undef CASE |
+ default: |
+ UNREACHABLE(); |
+ return 0; |
+ } |
+} |
+ |
+// static |
Callable Builtins::CallableFor(Isolate* isolate, Name name) { |
switch (name) { |
#define CASE(Name, ...) \ |