From 3c265f1bd4409c5713e88127e8fdca23870ea3c1 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E6=9C=80=E8=90=8C=E5=B0=8F=E6=B1=90?= Date: Mon, 8 Nov 2021 20:20:35 +0800 Subject: change to `@param ...` --- meta/template/bit.lua | 18 +++++++++--------- meta/template/io.lua | 10 +++++----- meta/template/math.lua | 4 ++-- meta/template/string.lua | 6 +++--- meta/template/utf8.lua | 2 +- 5 files changed, 20 insertions(+), 20 deletions(-) diff --git a/meta/template/bit.lua b/meta/template/bit.lua index 57bf6d31..369c5f9d 100644 --- a/meta/template/bit.lua +++ b/meta/template/bit.lua @@ -21,23 +21,23 @@ function bit.tohex(x, n) end ---@nodiscard function bit.bnot(x) end ----@param x integer ----@param x2 integer ----@vararg integer +---@param x integer +---@param x2 integer +---@param ... integer ---@return integer y ---@nodiscard function bit.bor(x, x2, ...) end ----@param x integer ----@param x2 integer ----@vararg integer +---@param x integer +---@param x2 integer +---@param ... integer ---@return integer y ---@nodiscard function bit.band(x, x2, ...) end ----@param x integer ----@param x2 integer ----@vararg integer +---@param x integer +---@param x2 integer +---@param ... integer ---@return integer y ---@nodiscard function bit.bxor(x, x2, ...) end diff --git a/meta/template/io.lua b/meta/template/io.lua index 1af572b6..b2846878 100644 --- a/meta/template/io.lua +++ b/meta/template/io.lua @@ -41,7 +41,7 @@ function io.input(file) end ---#DES 'io.lines' ---@param filename string? ----@vararg readmode +---@param ... readmode ---@return fun():string|number function io.lines(filename, ...) end @@ -70,7 +70,7 @@ function io.output(file) end function io.popen(prog, mode) end ---#DES 'io.read' ----@vararg readmode +---@param ... readmode ---@return string|number ---@return ... ---@nodiscard @@ -128,12 +128,12 @@ function file:close() end function file:flush() end ---#DES 'file:lines' ----@vararg readmode +---@param ... readmode ---@return fun():string|number function file:lines(...) end ---#DES 'file:read' ----@vararg readmode +---@param ... readmode ---@return string|number ---@nodiscard function file:read(...) end @@ -161,7 +161,7 @@ function file:seek(whence, offset) end function file:setvbuf(mode, size) end ---#DES 'file:write' ----@vararg string|number +---@param ... string|number ---@return file*? ---@return string? errmsg function file:write(...) end diff --git a/meta/template/math.lua b/meta/template/math.lua index 67c76ff4..09c75cc6 100644 --- a/meta/template/math.lua +++ b/meta/template/math.lua @@ -138,14 +138,14 @@ function math.log10(x) end ---#DES 'math.max' ---@param x number ----@vararg number +---@param ... number ---@return number ---@nodiscard function math.max(x, ...) end ---#DES 'math.min' ---@param x number ----@vararg number +---@param ... number ---@return number ---@nodiscard function math.min(x, ...) end diff --git a/meta/template/string.lua b/meta/template/string.lua index e61c3688..d3b4c431 100644 --- a/meta/template/string.lua +++ b/meta/template/string.lua @@ -15,7 +15,7 @@ function string.byte(s, i, j) end ---#DES 'string.char' ---@param byte integer ----@vararg integer +---@param ... integer ---@return string ---@return ... ---@nodiscard @@ -41,7 +41,7 @@ function string.find(s, pattern, init, plain) end ---#DES 'string.format' ---@param s string ----@vararg string +---@param ... string ---@return string ---@nodiscard function string.format(s, ...) end @@ -95,7 +95,7 @@ function string.match(s, pattern, init) end ---@param fmt string ---@param v1 string ---@param v2? string ----@vararg string +---@param ... string ---@return string binary ---@nodiscard function string.pack(fmt, v1, v2, ...) end diff --git a/meta/template/utf8.lua b/meta/template/utf8.lua index d3ff940e..bd474710 100644 --- a/meta/template/utf8.lua +++ b/meta/template/utf8.lua @@ -10,7 +10,7 @@ utf8 = {} ---#DES 'utf8.char' ---@param code integer ----@vararg integer +---@param ... integer ---@return string ---@nodiscard function utf8.char(code, ...) end -- cgit v1.2.3