Next: 6.1 Predefined Functions Up: Reference Manual of the Previous: 5.6 Locking Lua Objects

6 Predefined Functions and Libraries

The set of predefined functions in Lua is small but powerful. Most of them provide features that allows some degree of reflexivity in the language. Many of these features cannot be simulated with the rest of the Language nor with the standard API.

The libraries, on the other hand, provide useful routines that are implemented directly through the standard API. Therefore, they are not necessary to the language, and are provided as separated C modules. Currently there are three standard libraries:

In order to have access to these libraries, the host program must call the functions strlib_open, mathlib_open, and iolib_open, declared in lualib.h.


Next: 6.1 Predefined Functions Up: Reference Manual of the Previous: 5.6 Locking Lua Objects