@@ -654,6 +654,8 @@ string.pack =
654654' 返回一个打包了(即以二进制形式序列化) v1, v2 等值的二进制字符串。 字符串 fmt 为打包格式(参见 §6.4.2)。'
655655string .packsize =
656656[[ 返回以指定格式用 $string.pack 打包的字符串的长度。 格式化字符串中不可以有变长选项 's' 或 'z' (参见 §6.4.2)。]]
657+ string.rep [' >5.2' ] =
658+ ' 返回 `n` 个字符串 `s` 以字符串 `sep` 为分割符连在一起的字符串。 默认的 `sep` 值为空字符串(即没有分割符)。 如果 `n` 不是正数则返回空串。'
657659string.rep [' <5.1' ] =
658660' 返回 `n` 个字符串 `s` 连在一起的字符串。 如果 `n` 不是正数则返回空串。'
659661string.rep [' >5.2' ] =
@@ -684,36 +686,6 @@ a1[f],···,a1[e]
684686return a2
685687```
686688]]
687- string.rep [' >5.2' ] = -- TODO: need translate!
688- ' Returns a string that is the concatenation of `n` copies of the string `s` separated by the string `sep`.'
689- string.rep [' <5.1' ] = -- TODO: need translate!
690- ' Returns a string that is the concatenation of `n` copies of the string `s` .'
691- string .reverse = -- TODO: need translate!
692- ' Returns a string that is the string `s` reversed.'
693- string .sub = -- TODO: need translate!
694- ' Returns the substring of the string that starts at `i` and continues until `j`.'
695- string .unpack = -- TODO: need translate!
696- ' Returns the values packed in string according to the format string `fmt` (see §6.4.2) .'
697- string .upper = -- TODO: need translate!
698- ' Returns a copy of this string with all lowercase letters changed to uppercase.'
699-
700- table = -- TODO: need translate!
701- ' '
702- table .concat = -- TODO: need translate!
703- ' Given a list where all elements are strings or numbers, returns the string `list[i]..sep..list[i+1] ··· sep..list[j]`.'
704- table .insert = -- TODO: need translate!
705- ' Inserts element `value` at position `pos` in `list`.'
706- table .maxn = -- TODO: need translate!
707- ' Returns the largest positive numerical index of the given table, or zero if the table has no positive numerical indices.'
708- table .move = -- TODO: need translate!
709- [[
710- Moves elements from table `a1` to table `a2`.
711- ```lua
712- a2[t],··· =
713- a1[f],···,a1[e]
714- return a2
715- ```
716- ]]
717689table .pack =
718690' 返回用所有参数以键 `1`,`2`, 等填充的新表, 并将 `"n"` 这个域设为参数的总数。'
719691table .remove =
0 commit comments