Closed blefloch closed 6 years ago
Simpler case with the same error:
\unravel{ \ifcase 1 \expandafter \ifx \noexpand \X \X }
A variant:
\unravel{\edef\foo{\expandafter\ifx\noexpand\X\X\fi}}
It seems the problem is the combination of \expandafter
and \noexpand
: the wrong token (here \ifx
) is turned into \relax
.
Cases like \expandafter\show\expandafter\X\expandafter\show\noexpand\X
mean that the \noexpand
information really has to be stored with \X
itself at the right position in the input stream. This is tough given the current approach of unravel
. I'll think.
Also on \cs_generate_variant:Nn
.
This stops after 99 steps, despite being in the middle of many expansions.