diff options
Diffstat (limited to 'Build/source/texk/web2c/eptexdir/tests/pdfprimitive-test.tex')
-rw-r--r-- | Build/source/texk/web2c/eptexdir/tests/pdfprimitive-test.tex | 47 |
1 files changed, 47 insertions, 0 deletions
diff --git a/Build/source/texk/web2c/eptexdir/tests/pdfprimitive-test.tex b/Build/source/texk/web2c/eptexdir/tests/pdfprimitive-test.tex new file mode 100644 index 00000000000..2f7211d26c7 --- /dev/null +++ b/Build/source/texk/web2c/eptexdir/tests/pdfprimitive-test.tex @@ -0,0 +1,47 @@ +%#!euptex pdfprimitive-test.tex +\catcode`\{=1\catcode`\}=2 +\scrollmode +\catcode`\Q=14 +\ifdefined\pdfprimitive\else\catcode`\Q=11 \fi + +Q\let\pdfprimitive\primitive\let\ifpdfprimitive\ifprimitive +\catcode`\Q=11 + +\def\relax{\message{RELAX}} +\def\fuga{\message{FUGA}} +\let\input=\halign + +\relax % ==> RELAX +\pdfprimitive\relax % ==> (no output) +\message{\meaning\relax} % ==> macro:->\message {RELAX} + +\fuga % ==> FUGA +\pdfprimitive\fuga % ==> ``! Missing primitive name.'' error + +\ifpdfprimitive\relax\message{T}\else\message{F}\fi % ==> F (macro) +\ifpdfprimitive\par\message{T}\else\message{F}\fi % ==> T +\ifpdfprimitive\input\message{T}\else\message{F}\fi % ==> F + % (This \input is not ``primitive \input''.) +\ifpdfprimitive\hoge\message{T}\else\message{F}\fi % ==> F (undefined) +\ifpdfprimitive\fuga\message{T}\else\message{F}\fi % ==> F (macro) + +\show\pdfstrcmp % ==> \pdfstrcmp + +% fix for overwriting entries (170924) +\ifpdfprimitive\ \message{T}\else\message{F}\fi % ==> T +\ifpdfprimitive\vrule\message{T}\else\message{F}\fi % ==> T + +% fix for back_input in vertical mode (170924) +\setbox0=\vbox{\pdfprimitive\ \undefined} +% ==> ``! Undefined control sequence.'' error +\setbox0=\vbox{\pdfprimitive\vrule\undefined} +% ==> ``! Undefined control sequence.'' error + +\setbox0=\hbox{% + \def\A{\message{<\the\count42>}\ignorespaces} + \count42=\pdfprimitive\X 1\A + \count42=\pdfprimitive\- 2\A + \count42=\pdfprimitive\vrule 3\A +} + +\end |