LATEX-L Archives

Mailing list for the LaTeX3 project


Options: Use Forum View

Use Monospaced Font
Show Text Part by Default
Show All Mail Headers

Message: [<< First] [< Prev] [Next >] [Last >>]
Topic: [<< First] [< Prev] [Next >] [Last >>]
Author: [<< First] [< Prev] [Next >] [Last >>]

Print Reply
Bruno Le Floch <[log in to unmask]>
Reply To:
Mailing list for the LaTeX3 project <[log in to unmask]>
Sun, 13 Mar 2011 18:58:35 -0400
text/plain (1207 bytes) , quarktestfix.tex (1230 bytes)
> I need to read through everything, but as you are looking at a total
> reimplementation, more or less, do we really need two markers in a
> sequence? I've got an 'alternative' sequence system to work with just
> one (\q_seq), but at present it strips braces. (I know that because I
> checked after you started this thread: I'd have suggested my version
> otherwise!)
> --
> Joseph Wright

If we want to avoid losing braces, there are essentially two ways.
Either have two markers, `\seq_elt:w <item> \seq_elt_end:`, but the
code is tricky, or have one marker only, and braces, as `\seq_elt:n
{<item>}`. I'm essentially taking this from the TeXbook, p. 378 (and
thinking on my own, but well... I do trust Knuth's knowledge of TeX).

Will's version (and I guess yours if you use
`\quark_if_recursion_tail_stop:n`) breaks for items like
{{{{{{a}}}}}}, or some cases with conditionals. So let me also propose
a fix for `\quark_if_recursion_tail_stop:n` and friends (see attached
for examples where the current version is broken, and for the fix).
The new version should be \~10\% slower (not really checked that
claim), but would not break, although it would consider
`{}\q_recursion_tail` to be `\q_recursion_tail`.