Input/Output Library
Input/Output Library
Lua uses two flle handles by default for I/O operations. These handles are stored in the global variables _INPUT and _OUTPUT. A flle handle is a userdata containing the flle stream (FILE*), and with a distinctive tag created by the I/O library.Unless otherwise stated, all I/O functions return nil on failure and some value different from nil on success. These facilities are broadly similar to their C function equivalents.