29.05.2014 Views

The history of luaTEX 2006–2009 / v 0.50 - Pragma ADE

The history of luaTEX 2006–2009 / v 0.50 - Pragma ADE

The history of luaTEX 2006–2009 / v 0.50 - Pragma ADE

SHOW MORE
SHOW LESS

You also want an ePaper? Increase the reach of your titles

YUMPU automatically turns print PDFs into web optimized ePapers that Google loves.

...userdata")<br />

tex.print(help[1])<br />

}<br />

An even more isolated variant is:<br />

\startisolatedcode<br />

help = { "help" }<br />

tex.print(help and help[1] or "no help")<br />

\stopisolatedcode<br />

We get: ‘help’, while<br />

\startisolatedcode<br />

tex.print(help and help[1] or "no help")<br />

\stopisolatedcode<br />

gives: ‘no help’.<br />

You can get access to the global data <strong>of</strong> other named code blocks by using the global<br />

prex. At that level you have also access to the instances, but this time we append data,<br />

so user has a table userdata:<br />

For convenience we have made tex as well as some Lua tables directly accessible within<br />

an instance. However, we recommend not to extend these yourself (even if we do it in<br />

the core <strong>of</strong> MkIV).<br />

User code 299

Hooray! Your file is uploaded and ready to be published.

Saved successfully!

Ooh no, something went wrong!