sbarisic/gluac

gluac only reading the first line from STDIN

samuelmaddock opened this issue · 1 comments

When passing in text from STDIN, only the first line is read by gluac. Here's an example of usage:

cat test.lua | gluac -p -

where test.lua contains:

if test then
    print "string
end

The output from luac:

$ cat test.lua | luac -p -
luac: stdin:2: unfinished string near '"string'

and output from gluac:

$ cat test.lua | gluac -p -
error: [string "STDIN"]:1: 'end' expected near '<eof>'

As seen above, gluac is only reading from the first line of STDIN.

Fixed