Hello,
my question: is there a reason why \toksapp assignment cannot be set
expandable by \immediateassigned or \immediateassignment?
We can compare:
\immediateassigned{\toks0={abc} \toks0\ea{\the\toks0 xyz}}
it works. On the other hand:
\immediateassigned{\toks0={abc} \toksapp0{xyz}}
fails with error:
! This can't happen (prefix).
l.2 \immediateassigned{\toks0={abc} \toksapp
0{xyz}}
Where is a difference?
It should be great if \toksapp can be set expandable. I use it in my
macro \replstring. If very large strings are modified by this macro at
many points then there is significantly better calculation speed with
\toksapp than \toks\ea{\the\toks} (approximately ten times better). So
\toksapp is optimal but if it is used in a macro then the macro cannot
be set expandable.
Best regards
Petr Olsak