Prosody IM Website

file doc/developers/util/ in changeset 442216970d74

View latest ↓ Download file

line wrap: on
line source

abstract: 'Small library to complement Luas built-in table module'
title: 'util.table'

This library includes a few table related functions.

# create(narr, nrec) {#create_narr_nrec}

Direct interface to the Lua API function
which allows specifying how large a table to allocate.

# pack(\...) {#pack}

Packs all arguments into a sequence table along with the field `n` set
to the number of items. Basically the reverse of the
[unpack]( function
from the Lua standard library and identical to the
function introduced in Lua 5.2.