[luatex] Bugs in \input{...}

luigi scarso luigi.scarso at gmail.com
Mon Jan 27 15:29:13 CET 2020


On Mon, Jan 27, 2020 at 2:53 PM Phelype Oleinik <phe.h.o1 at gmail.com> wrote:

> Hello all,
>
> When using \input{...} inside an \edef the first token
> in the file disappears:
>
>     \directlua{\unexpanded{%
>       out = io.open('testfile.tex','w')
>       out:write('hello\\noexpand')
>       io.close(out)}}
>     \edef\tmpa{\input{testfile.tex}}\show\tmpa
>     % > \tmpa=macro:
>     % ello
>     \bye
>
> For some reason, it gets worse if the file starts
> with \noexpand\something:
>
>     \directlua{\unexpanded{%
>       out = io.open('testfile.tex','w')
>       out:write('\\noexpand\\hello\\noexpand')
>       io.close(out)}}
>     \edef\tmpa{\input{testfile.tex}}\show\tmpa
>     % > \tmpa=macro:
>     % <gibberish>
>     \bye
>
> If I use \edef\tmpa{\input testfile.tex } instead, both
> examples work as expected.
>

confirmed, thank you for the report.


-- 
luigi
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <https://tug.org/pipermail/luatex/attachments/20200127/d254d64b/attachment.html>


More information about the luatex mailing list.