Just to add, 12% is definitely wrong because it does not end the number, the number ends at a non-number. If you type \catcode`\~=12% 3 sons
you will get an error that 123 is not allowed here. You should end it either with a space or with a \relax. Zdeněk Wagner http://ttsm.icpf.cas.cz/team/wagner.shtml http://icebearsoft.euweb.cz čt 12. 11. 2020 v 11:36 odesílatel David Carlisle <d.p.carli...@gmail.com> napsal: > > > > \catcode`\~=12% > > changing catcodes in an environment looks wrong (the % after the 12 is > definitely wrong) if you change catcodes then the definition cannot work in > the argument of any command (for the same reasons that \verb does not work in > command arguments) . Leave ~ active but make it expand to the inactive one eg > > \edef~{\string~}% > >