lunarmodules/lua-compat-5.3

Support missing "*" in file:read formats

Closed this issue · 1 comments

Support missing * in file:read and file:lines formats.

$ lua -e 'print(io.stdin:read("a"))' <<< test
test

$ lua5.1 -l compat53 -e 'print(io.stdin:read("a"))' <<< test
lua5.1: (command line):1: bad argument #1 to 'read' (invalid option)
stack traceback:
    [C]: ?
    [C]: in function 'read'
    (command line):1: in main chunk
    [C]: ?