[luatex] tex.enableprimitives producing non-primitives?

Dohyun Kim nomosnomos at gmail.com
Wed Sep 23 14:35:47 CEST 2009


2009/9/23 Heiko Oberdiek <oberdiek at uni-freiburg.de>:
>
> \pdfprimitive does not know about tex.enableprimitives and does
> not care for the current meaning of \testprefixattribute.
> \pdfprimitive expects the same name as you use in the second
> argument of tex.enableprimitives.
>

But... what about \ifprimitive?
Please test a file as follows with "luatex -ini":
neither \attribute nor \testprefixattribute is treated as a primitive.
This makes \ifprimitive command useless.
In this respect, I agree with Élie Roux and think that this issue is a
luatex's bug.

\catcode`\{=1
\catcode`\}=2
\ifx\directlua\undefined
\else
 \directlua{tex.enableprimitives('',{'ifpdfprimitive'})}
 \directlua{tex.enableprimitives('testprefix',{'attribute'})}
\fi
\immediate\write17{ !!! attribute is
  \ifpdfprimitive\attribute\else NOT \fi a primitive.}
\immediate\write17{ !!! testprefixattribute is
  \ifpdfprimitive\testprefixattribute\else NOT \fi a primitive.}
\end

Regards,
Dohyun Kim


More information about the luatex mailing list