aboutsummaryrefslogtreecommitdiff
path: root/doc
diff options
context:
space:
mode:
Diffstat (limited to 'doc')
-rw-r--r--doc/extensions.html9
1 files changed, 9 insertions, 0 deletions
diff --git a/doc/extensions.html b/doc/extensions.html
index 33bcfb28..48f4220c 100644
--- a/doc/extensions.html
+++ b/doc/extensions.html
@@ -208,6 +208,15 @@ minor releases (2.0 → 2.1) or between any beta release. Foreign
208bytecode (e.g. from Lua 5.1) is incompatible and cannot be loaded. 208bytecode (e.g. from Lua 5.1) is incompatible and cannot be loaded.
209</p> 209</p>
210 210
211<h3 id="table_new"><tt>table.new(narray, nhash)</tt> allocates a pre-sized table</h3>
212<p>
213An extra library function <tt>table.new()</tt> can be made available via
214<tt>require("table.new")</tt>. This creates a pre-sized table, just like
215the C API equivalent <tt>lua_createtable()</tt>. This is useful for big
216tables if the final table size is known and automatic table resizing is
217too expensive.
218</p>
219
211<h3 id="math_random">Enhanced PRNG for <tt>math.random()</tt></h3> 220<h3 id="math_random">Enhanced PRNG for <tt>math.random()</tt></h3>
212<p> 221<p>
213LuaJIT uses a Tausworthe PRNG with period 2^223 to implement 222LuaJIT uses a Tausworthe PRNG with period 2^223 to implement