summaryrefslogtreecommitdiff
path: root/script/vm/function.lua
diff options
context:
space:
mode:
Diffstat (limited to 'script/vm/function.lua')
-rw-r--r--script/vm/function.lua4
1 files changed, 4 insertions, 0 deletions
diff --git a/script/vm/function.lua b/script/vm/function.lua
index 6c07acf6..9efcbd32 100644
--- a/script/vm/function.lua
+++ b/script/vm/function.lua
@@ -29,6 +29,10 @@ function vm.countParamsOfFunction(func)
local arg = func.args[i]
if arg.type == '...' then
max = math.huge
+ elseif arg.type == 'self'
+ and i == 1 then
+ min = i
+ break
elseif getDocParam(arg)
and not vm.compileNode(arg):isNullable() then
min = i