aboutsummaryrefslogtreecommitdiff
path: root/modules/lua/lua.luadoc
diff options
context:
space:
mode:
authormitchell <70453897+667e-11@users.noreply.github.com>2013-02-25 20:04:06 -0500
committermitchell <70453897+667e-11@users.noreply.github.com>2013-02-25 20:04:06 -0500
commit79c5af64a7490b6d737d5093ec20ddcc6781fa75 (patch)
treecdcda6d857bd4ccabbcb1c5cfe4a1f6dbf76e8ac /modules/lua/lua.luadoc
parent5fbe13053cb6fa27cc457c8bd654d413d30671d8 (diff)
downloadtextadept-79c5af64a7490b6d737d5093ec20ddcc6781fa75.tar.gz
textadept-79c5af64a7490b6d737d5093ec20ddcc6781fa75.zip
Updated Lua apidocs to 5.2.1.
Diffstat (limited to 'modules/lua/lua.luadoc')
-rw-r--r--modules/lua/lua.luadoc15
1 files changed, 8 insertions, 7 deletions
diff --git a/modules/lua/lua.luadoc b/modules/lua/lua.luadoc
index a288c6c9..a3ed8b41 100644
--- a/modules/lua/lua.luadoc
+++ b/modules/lua/lua.luadoc
@@ -538,16 +538,17 @@ function string.gmatch(s, pattern) end
-- If `repl` is a string, then its value is used for replacement. The character
-- `%` works as an escape character: any sequence in `repl` of the form `%d`,
-- with `d` between 1 and 9, stands for the value of the `d`-th captured
--- substring (see below). The sequence `%0` stands for the whole match. The
--- sequence `%%` stands for a single `%`.
+-- substring. The sequence `%0` stands for the whole match. The sequence `%%`
+-- stands for a single `%`.
--
-- If `repl` is a table, then the table is queried for every match, using
--- the first capture as the key; if the pattern specifies no captures, then
--- the whole match is used as the key.
+-- the first capture as the key.
+--
-- If `repl` is a function, then this function is called every time a match
--- occurs, with all captured substrings passed as arguments, in order; if
--- the pattern specifies no captures, then the whole match is passed as a
--- sole argument.
+-- occurs, with all captured substrings passed as arguments, in order.
+--
+-- In any case, if the pattern specifies no captures, then it behaves as if the
+-- whole pattern was inside a capture.
--
-- If the value returned by the table query or by the function call is a
-- string or a number, then it is used as the replacement string; otherwise,