[texhax] read argument until EOL

Philip Taylor (Webmaster, Ret'd) P.Taylor at Rhul.Ac.Uk
Fri Jan 7 17:14:55 CET 2011

Heiko Oberdiek wrote:

> "1" might have the wrong uccode different than 0 or `1.
> (But I would consider it as quite small risk.)

I think that this code addresses that point, Heiko, but of
course there are many other things that assume a standard
environment : for example, should I also explicitly (re-)set
the \catcode of "~" ?  If so, what about the all the other
characters used, all of which are assumed in my version to
have their standard \catcode s at the point of elaboration ?
How far should one go, in programming defensively ?

** Phil.
     \def \eolsection
     		\catcode `\^^M = \active
		\uccode `\1 = 0
		\uccode `\~ = `\^^M
		\uppercase {\def \innereolsection ##1~}{\endgroup \message {##1}}\relax

     \eolsection AAA

     \eolsection BBB

     \eolsection CCC


More information about the texhax mailing list