[latex3-commits] [latex3/latex2e] develop: Detail brace handling by \SplitList (d1b701fa)

github at latex-project.org github at latex-project.org
Wed May 17 08:06:04 CEST 2023


Repository : https://github.com/latex3/latex2e
On branch  : develop
Link       : https://github.com/latex3/latex2e/commit/d1b701fae29383c09be17c8433f4969f1908319e

>---------------------------------------------------------------

commit d1b701fae29383c09be17c8433f4969f1908319e
Author: Joseph Wright <joseph.wright at morningstar2.co.uk>
Date:   Wed May 17 07:05:09 2023 +0100

    Detail brace handling by \SplitList


>---------------------------------------------------------------

d1b701fae29383c09be17c8433f4969f1908319e
 base/changes.txt      |  4 ++++
 base/doc/usrguide.tex | 14 +++++++++++++-
 2 files changed, 17 insertions(+), 1 deletion(-)

diff --git a/base/changes.txt b/base/changes.txt
index 05442a95..45d85d9f 100644
--- a/base/changes.txt
+++ b/base/changes.txt
@@ -10,6 +10,10 @@ are not part of the distribution.
 	* ltxref.dtx
 	extend \label to store five values and add a hook with argument
 
+2023-05-17  Joseph Wright  <Joseph.Wright at latex-project.org>
+
+	* usrguide.tex (subsection Argument processors)
+	  Add details of brace stripping by \SplitList
 
 2023-05-13  David Carlisle  <David.Carlisle at latex-project.org>
 
diff --git a/base/doc/usrguide.tex b/base/doc/usrguide.tex
index fb291ac2..590a9190 100644
--- a/base/doc/usrguide.tex
+++ b/base/doc/usrguide.tex
@@ -636,7 +636,19 @@ processed argument can be further processed using a mapping function
 If only a single character \meta{token} is used for the split, any
 category code $13$ (active) character matching the \meta{token} will
 be replaced before the split takes place.
-Spaces are trimmed at each end of each item parsed.
+Spaces are trimmed at each end of each item parsed. Exactly one set
+of braces will be stripped if an entire item is surrounded by them,
+i.e.~the following inputs and outputs result (each separte item as
+a brace group).
+\begin{verbatim}
+a      ==> {a}
+{a}    ==> {a}
+{a}b   ==> {{a}b}
+a,b    ==> {a}{b}
+{a},b  ==> {a}{b}
+a,{b}  ==> {a}{b}
+a,{b}c ==> {a}{{b}c}
+\end{verbatim}
 
 \begin{decl}
   |\ProcessList| \arg{list} \arg{function}





More information about the latex3-commits mailing list.