[Dev-luatex] "error" in LuaTeX and Lua

Taco Hoekwater taco at elvenkind.com
Tue Apr 29 14:17:06 CEST 2008



Jonathan Sauer wrote:
> Hello,
> 
>>> BTW: loadstring can be passed a chunk name. Is it be possible to do
>>> the same with \directlua? (to replace "[string "luas[0]"]" above)
>> Something like \directlua callback chunk {...} you mean?
> 
> Yes. Maybe \directlua cname {My chunk name} {...} (since it is the name
> of the chunk, not specifically the name used in the callback/traceback).

This idea is very interesting.  I have committed an experimental patch
that extends \directlua syntax so that besides

    \directlua <number> <general text>

it also allows a keyword prefix:

    \directlua name <general text> <number> <general text>

This allows you to do stuff like this:

    \directlua name {\jobname-\the\inputlineno} 0 {error('test')}

Because it is experimental, it only works for \directlua, not
yet for \latelua.

Best wishes,
Taco



More information about the dev-luatex mailing list