View Issue Details

IDProjectCategoryView StatusLast Update
0000551luatexdocumentationpublic2015-10-20 20:22
ReporterTaco Assigned ToTaco  
PrioritynormalSeverityminorReproducibilityhave not tried
Status closedResolutionfixed 
Summary0000551: token library documentation is bad
DescriptionFrom Philipp Stefani:

- token.get_next() removes the next token, which is not documented
- the meaning of the entries of the token tables is undocumented
- the documented values for the "mode" key in the semantic nest level tables are wrong:

\def\printmode#1{%
  \directlua{%
    tex.sprint(tostring(tex.nest[tex.nest.ptr].mode) .. [[ 0000001]])
  }%
}

\printmode{= 1 = vertical} % print 1, correct

\vbox{
  \printmode{= -1 = internal vertical} % prints -1, correct
}

a \printmode{= 127 = horizontal} % prints 118

\hbox{
  \printmode{= -127 = restricted horizontal} % prints -118
}

$$
\printmode{= 253 = display math} % prints 235
$$

$
\printmode{= -253 = inline math} % prints -235
$

\bye

Please use symbolic constants instead of magic numbers for such things. TeX has already too many magic numbers, and this unfortunate tradition should not continue.

TagsNo tags attached.

Activities

Hans Hagen

2015-10-20 20:22

manager   ~0001439

new lib

Issue History

Date Modified Username Field Change
2011-01-07 13:25 Taco New Issue
2011-01-07 13:27 Taco Description Updated
2011-02-10 10:37 Taco Status new => assigned
2011-02-10 10:37 Taco Assigned To => Taco
2015-10-20 20:22 Hans Hagen Note Added: 0001439
2015-10-20 20:22 Hans Hagen Status assigned => closed
2015-10-20 20:22 Hans Hagen Resolution open => fixed