summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorKarl Berry <karl@freefriends.org>2020-05-14 21:16:02 +0000
committerKarl Berry <karl@freefriends.org>2020-05-14 21:16:02 +0000
commitbb587f3190ec7933ee6a18e994099e566c6e8009 (patch)
tree6619bbe50d37ded7861833bc580028c2a8cca64c
parent9e186a1e49f4a0ef3154b453e114e0e7adc6ae6c (diff)
l3 (14may20)
git-svn-id: svn://tug.org/texlive/trunk@55142 c570f23f-e606-0410-a88d-b1316a301751
-rw-r--r--Master/texmf-dist/doc/latex/l3kernel/CHANGELOG.md8
-rw-r--r--Master/texmf-dist/doc/latex/l3kernel/README.md2
-rw-r--r--Master/texmf-dist/doc/latex/l3kernel/expl3.pdfbin584772 -> 584879 bytes
-rw-r--r--Master/texmf-dist/doc/latex/l3kernel/interface3.pdfbin1544205 -> 1544503 bytes
-rw-r--r--Master/texmf-dist/doc/latex/l3kernel/interface3.tex2
-rw-r--r--Master/texmf-dist/doc/latex/l3kernel/l3docstrip.pdfbin263360 -> 263493 bytes
-rw-r--r--Master/texmf-dist/doc/latex/l3kernel/l3news.pdfbin379248 -> 379248 bytes
-rw-r--r--Master/texmf-dist/doc/latex/l3kernel/l3news01.pdfbin113529 -> 113529 bytes
-rw-r--r--Master/texmf-dist/doc/latex/l3kernel/l3news02.pdfbin140776 -> 140776 bytes
-rw-r--r--Master/texmf-dist/doc/latex/l3kernel/l3news03.pdfbin144784 -> 144784 bytes
-rw-r--r--Master/texmf-dist/doc/latex/l3kernel/l3news04.pdfbin107117 -> 107117 bytes
-rw-r--r--Master/texmf-dist/doc/latex/l3kernel/l3news05.pdfbin105090 -> 105090 bytes
-rw-r--r--Master/texmf-dist/doc/latex/l3kernel/l3news06.pdfbin140797 -> 140797 bytes
-rw-r--r--Master/texmf-dist/doc/latex/l3kernel/l3news07.pdfbin119092 -> 119092 bytes
-rw-r--r--Master/texmf-dist/doc/latex/l3kernel/l3news08.pdfbin152413 -> 152413 bytes
-rw-r--r--Master/texmf-dist/doc/latex/l3kernel/l3news09.pdfbin235323 -> 235323 bytes
-rw-r--r--Master/texmf-dist/doc/latex/l3kernel/l3news10.pdfbin147096 -> 147096 bytes
-rw-r--r--Master/texmf-dist/doc/latex/l3kernel/l3news11.pdfbin165956 -> 165956 bytes
-rw-r--r--Master/texmf-dist/doc/latex/l3kernel/l3news12.pdfbin199153 -> 199153 bytes
-rw-r--r--Master/texmf-dist/doc/latex/l3kernel/l3prefixes.csv3
-rw-r--r--Master/texmf-dist/doc/latex/l3kernel/l3prefixes.pdfbin75066 -> 75377 bytes
-rw-r--r--Master/texmf-dist/doc/latex/l3kernel/l3styleguide.pdfbin280109 -> 280191 bytes
-rw-r--r--Master/texmf-dist/doc/latex/l3kernel/l3styleguide.tex2
-rw-r--r--Master/texmf-dist/doc/latex/l3kernel/l3syntax-changes.pdfbin228403 -> 228503 bytes
-rw-r--r--Master/texmf-dist/doc/latex/l3kernel/l3syntax-changes.tex2
-rw-r--r--Master/texmf-dist/doc/latex/l3kernel/l3term-glossary.pdfbin186619 -> 186719 bytes
-rw-r--r--Master/texmf-dist/doc/latex/l3kernel/l3term-glossary.tex2
-rw-r--r--Master/texmf-dist/doc/latex/l3kernel/source3.pdfbin5890263 -> 5898773 bytes
-rw-r--r--Master/texmf-dist/doc/latex/l3kernel/source3.tex2
-rw-r--r--Master/texmf-dist/doc/latex/l3packages/CHANGELOG.md8
-rw-r--r--Master/texmf-dist/doc/latex/l3packages/README.md2
-rw-r--r--Master/texmf-dist/doc/latex/l3packages/l3keys2e/l3keys2e.pdfbin347543 -> 347720 bytes
-rw-r--r--Master/texmf-dist/doc/latex/l3packages/xfp/xfp.pdfbin309887 -> 310099 bytes
-rw-r--r--Master/texmf-dist/doc/latex/l3packages/xfrac/xfrac.pdfbin454318 -> 454527 bytes
-rw-r--r--Master/texmf-dist/doc/latex/l3packages/xparse/xparse.pdfbin505893 -> 506103 bytes
-rw-r--r--Master/texmf-dist/doc/latex/l3packages/xtemplate/xtemplate.pdfbin416401 -> 416612 bytes
-rw-r--r--Master/texmf-dist/source/latex/l3kernel/expl3.dtx4
-rw-r--r--Master/texmf-dist/source/latex/l3kernel/l3alloc.dtx2
-rw-r--r--Master/texmf-dist/source/latex/l3kernel/l3basics.dtx2
-rw-r--r--Master/texmf-dist/source/latex/l3kernel/l3bootstrap.dtx2
-rw-r--r--Master/texmf-dist/source/latex/l3kernel/l3box.dtx2
-rw-r--r--Master/texmf-dist/source/latex/l3kernel/l3candidates.dtx2
-rw-r--r--Master/texmf-dist/source/latex/l3kernel/l3clist.dtx2
-rw-r--r--Master/texmf-dist/source/latex/l3kernel/l3coffins.dtx2
-rw-r--r--Master/texmf-dist/source/latex/l3kernel/l3color-base.dtx2
-rw-r--r--Master/texmf-dist/source/latex/l3kernel/l3debug.dtx2
-rw-r--r--Master/texmf-dist/source/latex/l3kernel/l3deprecation.dtx2
-rw-r--r--Master/texmf-dist/source/latex/l3kernel/l3doc.dtx2
-rw-r--r--Master/texmf-dist/source/latex/l3kernel/l3docstrip.dtx2
-rw-r--r--Master/texmf-dist/source/latex/l3kernel/l3expan.dtx2
-rw-r--r--Master/texmf-dist/source/latex/l3kernel/l3file.dtx2
-rw-r--r--Master/texmf-dist/source/latex/l3kernel/l3final.dtx2
-rw-r--r--Master/texmf-dist/source/latex/l3kernel/l3flag.dtx2
-rw-r--r--Master/texmf-dist/source/latex/l3kernel/l3fp-assign.dtx2
-rw-r--r--Master/texmf-dist/source/latex/l3kernel/l3fp-aux.dtx2
-rw-r--r--Master/texmf-dist/source/latex/l3kernel/l3fp-basics.dtx2
-rw-r--r--Master/texmf-dist/source/latex/l3kernel/l3fp-convert.dtx2
-rw-r--r--Master/texmf-dist/source/latex/l3kernel/l3fp-expo.dtx2
-rw-r--r--Master/texmf-dist/source/latex/l3kernel/l3fp-extended.dtx2
-rw-r--r--Master/texmf-dist/source/latex/l3kernel/l3fp-logic.dtx2
-rw-r--r--Master/texmf-dist/source/latex/l3kernel/l3fp-parse.dtx2
-rw-r--r--Master/texmf-dist/source/latex/l3kernel/l3fp-random.dtx2
-rw-r--r--Master/texmf-dist/source/latex/l3kernel/l3fp-round.dtx2
-rw-r--r--Master/texmf-dist/source/latex/l3kernel/l3fp-traps.dtx2
-rw-r--r--Master/texmf-dist/source/latex/l3kernel/l3fp-trig.dtx2
-rw-r--r--Master/texmf-dist/source/latex/l3kernel/l3fp.dtx2
-rw-r--r--Master/texmf-dist/source/latex/l3kernel/l3fparray.dtx2
-rw-r--r--Master/texmf-dist/source/latex/l3kernel/l3int.dtx2
-rw-r--r--Master/texmf-dist/source/latex/l3kernel/l3intarray.dtx2
-rw-r--r--Master/texmf-dist/source/latex/l3kernel/l3kernel-functions.dtx2
-rw-r--r--Master/texmf-dist/source/latex/l3kernel/l3keys.dtx385
-rw-r--r--Master/texmf-dist/source/latex/l3kernel/l3legacy.dtx2
-rw-r--r--Master/texmf-dist/source/latex/l3kernel/l3luatex.dtx2
-rw-r--r--Master/texmf-dist/source/latex/l3kernel/l3msg.dtx2
-rw-r--r--Master/texmf-dist/source/latex/l3kernel/l3names.dtx2
-rw-r--r--Master/texmf-dist/source/latex/l3kernel/l3prg.dtx2
-rw-r--r--Master/texmf-dist/source/latex/l3kernel/l3prop.dtx2
-rw-r--r--Master/texmf-dist/source/latex/l3kernel/l3quark.dtx2
-rw-r--r--Master/texmf-dist/source/latex/l3kernel/l3regex.dtx2
-rw-r--r--Master/texmf-dist/source/latex/l3kernel/l3seq.dtx2
-rw-r--r--Master/texmf-dist/source/latex/l3kernel/l3skip.dtx2
-rw-r--r--Master/texmf-dist/source/latex/l3kernel/l3sort.dtx2
-rw-r--r--Master/texmf-dist/source/latex/l3kernel/l3str-convert.dtx2
-rw-r--r--Master/texmf-dist/source/latex/l3kernel/l3str.dtx2
-rw-r--r--Master/texmf-dist/source/latex/l3kernel/l3sys.dtx2
-rw-r--r--Master/texmf-dist/source/latex/l3kernel/l3text-case.dtx2
-rw-r--r--Master/texmf-dist/source/latex/l3kernel/l3text-purify.dtx2
-rw-r--r--Master/texmf-dist/source/latex/l3kernel/l3text.dtx2
-rw-r--r--Master/texmf-dist/source/latex/l3kernel/l3tl-analysis.dtx2
-rw-r--r--Master/texmf-dist/source/latex/l3kernel/l3tl.dtx2
-rw-r--r--Master/texmf-dist/source/latex/l3kernel/l3token.dtx2
-rw-r--r--Master/texmf-dist/source/latex/l3kernel/l3unicode.dtx2
-rw-r--r--Master/texmf-dist/source/latex/l3packages/l3keys2e/l3keys2e.dtx8
-rw-r--r--Master/texmf-dist/source/latex/l3packages/xfp/xfp.dtx4
-rw-r--r--Master/texmf-dist/source/latex/l3packages/xfrac/xfrac.dtx4
-rw-r--r--Master/texmf-dist/source/latex/l3packages/xparse/xparse.dtx148
-rw-r--r--Master/texmf-dist/source/latex/l3packages/xparse/xparse.ins5
-rw-r--r--Master/texmf-dist/source/latex/l3packages/xtemplate/xtemplate.dtx52
-rw-r--r--Master/texmf-dist/tex/latex/l3kernel/expl3-code.tex204
-rw-r--r--Master/texmf-dist/tex/latex/l3kernel/expl3-generic.tex2
-rw-r--r--Master/texmf-dist/tex/latex/l3kernel/expl3.ltx2
-rw-r--r--Master/texmf-dist/tex/latex/l3kernel/expl3.sty2
-rw-r--r--Master/texmf-dist/tex/latex/l3packages/l3keys2e/l3keys2e.sty6
-rw-r--r--Master/texmf-dist/tex/latex/l3packages/xfp/xfp.sty2
-rw-r--r--Master/texmf-dist/tex/latex/l3packages/xfrac/xfrac.sty2
-rw-r--r--Master/texmf-dist/tex/latex/l3packages/xparse/xparse-generic.tex2283
-rw-r--r--Master/texmf-dist/tex/latex/l3packages/xparse/xparse.ltx143
-rw-r--r--Master/texmf-dist/tex/latex/l3packages/xparse/xparse.sty2230
-rw-r--r--Master/texmf-dist/tex/latex/l3packages/xtemplate/xtemplate.sty32
109 files changed, 2955 insertions, 2704 deletions
diff --git a/Master/texmf-dist/doc/latex/l3kernel/CHANGELOG.md b/Master/texmf-dist/doc/latex/l3kernel/CHANGELOG.md
index 5baa671d014..41cffac254b 100644
--- a/Master/texmf-dist/doc/latex/l3kernel/CHANGELOG.md
+++ b/Master/texmf-dist/doc/latex/l3kernel/CHANGELOG.md
@@ -7,6 +7,11 @@ this project uses date-based 'snapshot' version identifiers.
## [Unreleased]
+## [2020-05-14]
+
+### Changed
+- Performance improvements in keyval processing
+
## [2020-05-11]
### Changed
@@ -678,7 +683,8 @@ this project uses date-based 'snapshot' version identifiers.
- Step func­tions have been added for dim vari­ables,
e.g. `\dim_step_in­line:nnnn`
-[Unreleased]: https://github.com/latex3/latex3/compare/2020-05-11...HEAD
+[Unreleased]: https://github.com/latex3/latex3/compare/2020-05-14...HEAD
+[2020-05-14]: https://github.com/latex3/latex3/compare/2020-05-11...2020-05-14
[2020-05-11]: https://github.com/latex3/latex3/compare/2020-05-05...2020-05-11
[2020-05-05]: https://github.com/latex3/latex3/compare/2020-04-06...2020-05-05
[2020-04-06]: https://github.com/latex3/latex3/compare/2020-03-06...2020-04-06
diff --git a/Master/texmf-dist/doc/latex/l3kernel/README.md b/Master/texmf-dist/doc/latex/l3kernel/README.md
index 3a7c3730b9e..99f233c0e86 100644
--- a/Master/texmf-dist/doc/latex/l3kernel/README.md
+++ b/Master/texmf-dist/doc/latex/l3kernel/README.md
@@ -1,7 +1,7 @@
LaTeX3 Programming Conventions
==============================
-Release 2020-05-11
+Release 2020-05-14
Overview
--------
diff --git a/Master/texmf-dist/doc/latex/l3kernel/expl3.pdf b/Master/texmf-dist/doc/latex/l3kernel/expl3.pdf
index b16b80e0c70..454be4b399c 100644
--- a/Master/texmf-dist/doc/latex/l3kernel/expl3.pdf
+++ b/Master/texmf-dist/doc/latex/l3kernel/expl3.pdf
Binary files differ
diff --git a/Master/texmf-dist/doc/latex/l3kernel/interface3.pdf b/Master/texmf-dist/doc/latex/l3kernel/interface3.pdf
index f91da62ed4c..5914895ef14 100644
--- a/Master/texmf-dist/doc/latex/l3kernel/interface3.pdf
+++ b/Master/texmf-dist/doc/latex/l3kernel/interface3.pdf
Binary files differ
diff --git a/Master/texmf-dist/doc/latex/l3kernel/interface3.tex b/Master/texmf-dist/doc/latex/l3kernel/interface3.tex
index e1b46c0897f..5007307c178 100644
--- a/Master/texmf-dist/doc/latex/l3kernel/interface3.tex
+++ b/Master/texmf-dist/doc/latex/l3kernel/interface3.tex
@@ -54,7 +54,7 @@ for those people who are interested.
{latex-team@latex-project.org}%
}%
}
-\date{Released 2020-05-11}
+\date{Released 2020-05-14}
\pagenumbering{roman}
\maketitle
diff --git a/Master/texmf-dist/doc/latex/l3kernel/l3docstrip.pdf b/Master/texmf-dist/doc/latex/l3kernel/l3docstrip.pdf
index 870f43aacb5..c01f5c66661 100644
--- a/Master/texmf-dist/doc/latex/l3kernel/l3docstrip.pdf
+++ b/Master/texmf-dist/doc/latex/l3kernel/l3docstrip.pdf
Binary files differ
diff --git a/Master/texmf-dist/doc/latex/l3kernel/l3news.pdf b/Master/texmf-dist/doc/latex/l3kernel/l3news.pdf
index d3d8cd3d8ae..5d5f7c9e6ea 100644
--- a/Master/texmf-dist/doc/latex/l3kernel/l3news.pdf
+++ b/Master/texmf-dist/doc/latex/l3kernel/l3news.pdf
Binary files differ
diff --git a/Master/texmf-dist/doc/latex/l3kernel/l3news01.pdf b/Master/texmf-dist/doc/latex/l3kernel/l3news01.pdf
index e7e64883a38..214fd413d7e 100644
--- a/Master/texmf-dist/doc/latex/l3kernel/l3news01.pdf
+++ b/Master/texmf-dist/doc/latex/l3kernel/l3news01.pdf
Binary files differ
diff --git a/Master/texmf-dist/doc/latex/l3kernel/l3news02.pdf b/Master/texmf-dist/doc/latex/l3kernel/l3news02.pdf
index 54d75387b2d..3842c435e31 100644
--- a/Master/texmf-dist/doc/latex/l3kernel/l3news02.pdf
+++ b/Master/texmf-dist/doc/latex/l3kernel/l3news02.pdf
Binary files differ
diff --git a/Master/texmf-dist/doc/latex/l3kernel/l3news03.pdf b/Master/texmf-dist/doc/latex/l3kernel/l3news03.pdf
index 60aa4d7d5db..b8be0aefdab 100644
--- a/Master/texmf-dist/doc/latex/l3kernel/l3news03.pdf
+++ b/Master/texmf-dist/doc/latex/l3kernel/l3news03.pdf
Binary files differ
diff --git a/Master/texmf-dist/doc/latex/l3kernel/l3news04.pdf b/Master/texmf-dist/doc/latex/l3kernel/l3news04.pdf
index 2165c12d768..a63902984d4 100644
--- a/Master/texmf-dist/doc/latex/l3kernel/l3news04.pdf
+++ b/Master/texmf-dist/doc/latex/l3kernel/l3news04.pdf
Binary files differ
diff --git a/Master/texmf-dist/doc/latex/l3kernel/l3news05.pdf b/Master/texmf-dist/doc/latex/l3kernel/l3news05.pdf
index 56d2d5f6001..db82fc240e1 100644
--- a/Master/texmf-dist/doc/latex/l3kernel/l3news05.pdf
+++ b/Master/texmf-dist/doc/latex/l3kernel/l3news05.pdf
Binary files differ
diff --git a/Master/texmf-dist/doc/latex/l3kernel/l3news06.pdf b/Master/texmf-dist/doc/latex/l3kernel/l3news06.pdf
index 4c0f81e8cb4..cfd3bd38e47 100644
--- a/Master/texmf-dist/doc/latex/l3kernel/l3news06.pdf
+++ b/Master/texmf-dist/doc/latex/l3kernel/l3news06.pdf
Binary files differ
diff --git a/Master/texmf-dist/doc/latex/l3kernel/l3news07.pdf b/Master/texmf-dist/doc/latex/l3kernel/l3news07.pdf
index f90ddaf6b16..d78833f8b5e 100644
--- a/Master/texmf-dist/doc/latex/l3kernel/l3news07.pdf
+++ b/Master/texmf-dist/doc/latex/l3kernel/l3news07.pdf
Binary files differ
diff --git a/Master/texmf-dist/doc/latex/l3kernel/l3news08.pdf b/Master/texmf-dist/doc/latex/l3kernel/l3news08.pdf
index 0061ae2c850..5757976cefc 100644
--- a/Master/texmf-dist/doc/latex/l3kernel/l3news08.pdf
+++ b/Master/texmf-dist/doc/latex/l3kernel/l3news08.pdf
Binary files differ
diff --git a/Master/texmf-dist/doc/latex/l3kernel/l3news09.pdf b/Master/texmf-dist/doc/latex/l3kernel/l3news09.pdf
index 149274576f2..6be892cf799 100644
--- a/Master/texmf-dist/doc/latex/l3kernel/l3news09.pdf
+++ b/Master/texmf-dist/doc/latex/l3kernel/l3news09.pdf
Binary files differ
diff --git a/Master/texmf-dist/doc/latex/l3kernel/l3news10.pdf b/Master/texmf-dist/doc/latex/l3kernel/l3news10.pdf
index c6b222cbb45..b79ce666243 100644
--- a/Master/texmf-dist/doc/latex/l3kernel/l3news10.pdf
+++ b/Master/texmf-dist/doc/latex/l3kernel/l3news10.pdf
Binary files differ
diff --git a/Master/texmf-dist/doc/latex/l3kernel/l3news11.pdf b/Master/texmf-dist/doc/latex/l3kernel/l3news11.pdf
index ea68c023214..a6e28784264 100644
--- a/Master/texmf-dist/doc/latex/l3kernel/l3news11.pdf
+++ b/Master/texmf-dist/doc/latex/l3kernel/l3news11.pdf
Binary files differ
diff --git a/Master/texmf-dist/doc/latex/l3kernel/l3news12.pdf b/Master/texmf-dist/doc/latex/l3kernel/l3news12.pdf
index d8e01270114..4988c454a70 100644
--- a/Master/texmf-dist/doc/latex/l3kernel/l3news12.pdf
+++ b/Master/texmf-dist/doc/latex/l3kernel/l3news12.pdf
Binary files differ
diff --git a/Master/texmf-dist/doc/latex/l3kernel/l3prefixes.csv b/Master/texmf-dist/doc/latex/l3kernel/l3prefixes.csv
index bf6e968edca..ad48bfaa101 100644
--- a/Master/texmf-dist/doc/latex/l3kernel/l3prefixes.csv
+++ b/Master/texmf-dist/doc/latex/l3kernel/l3prefixes.csv
@@ -40,6 +40,7 @@ csvsim,csvsimple,Thomas F. Sturm,https://github.com/T-F-S/csvsimple,https://gith
ctex,ctex,Qing Lee,https://github.com/CTeX-org/ctex-kit,https://github.com/CTeX-org/ctex-kit.git,https://github.com/CTeX-org/ctex-kit/issues,2014-03-08,2014-03-08,
ctuthesis,ctuthesis,Tom Hejda,https://github.com/tohecz/ctuthesis,https://github.com/tohecz/ctuthesis.git,https://github.com/tohecz/ctuthesis/issues,2015-07-26,2015-07-26,
debug,l3kernel,The LaTeX3 Project,https://www.latex-project.org/latex3.html,https://github.com/latex3/latex3.git,https://github.com/latex3/latex3/issues,2017-07-15,2017-07-15,
+denisbdoc,denisbdoc,Denis Bitouzé,https://github.com/dbitouze/denisbdoc,git@github.com:dbitouze/denisbdoc.git,2020-05-13,2020-05-13,
deriv,derivative,Simon Jensen,,,,2019-07-24,2019-07-24,
diffcoeff,diffcoeff,Andrew Parsloe,,,,2019-08-26,2019-08-26,
dim,l3kernel,The LaTeX3 Project,https://www.latex-project.org/latex3.html,https://github.com/latex3/latex3.git,https://github.com/latex3/latex3/issues,2012-09-27,2012-09-27,
@@ -81,6 +82,7 @@ ghsystem,ghsystem,Clemens Niederberger,https://github.com/cgnieder/ghsystem/,htt
graph,lt3graph,Michiel Helvensteijn,,,,2014-02-05,2014-02-05,
group,l3kernel,The LaTeX3 Project,https://www.latex-project.org/latex3.html,https://github.com/latex3/latex3.git,https://github.com/latex3/latex3/issues,2012-09-27,2012-09-27,
gtl,gtl,Bruno Le Floch,https://github.com/blefloch/latex-gtl,https://github.com/blefloch/latex-gtl.git,https://github.com/blefloch/latex-gtl/issues,2015-09-22,2015-09-22,
+gzt,gzt,Denis Bitouzé,https://github.com/dbitouze/gzt,git@github.com:dbitouze/gzt.git,2020-05-13,2020-05-13,
hash,l3kernel,The LaTeX3 Project,https://www.latex-project.org/latex3.html,https://github.com/latex3/latex3.git,https://github.com/latex3/latex3/issues,2018-05-12,2018-05-12,
hbox,l3kernel,The LaTeX3 Project,https://www.latex-project.org/latex3.html,https://github.com/latex3/latex3.git,https://github.com/latex3/latex3/issues,2012-09-27,2012-09-27,
hcoffin,l3kernel,The LaTeX3 Project,https://www.latex-project.org/latex3.html,https://github.com/latex3/latex3.git,https://github.com/latex3/latex3/issues,2012-09-28,2012-09-28,
@@ -123,6 +125,7 @@ nil,l3kernel,The LaTeX3 Project,https://www.latex-project.org/latex3.html,https:
no,l3kernel,The LaTeX3 Project,https://www.latex-project.org/latex3.html,https://github.com/latex3/latex3.git,https://github.com/latex3/latex3/issues,2018-05-12,2018-05-12,
notestobib,notes2bib,Joseph Wright,https://github.com/josephwright/notes2bib,https://github.com/josephwright/notes2bib.git,https://github.com/josephwright/notes2bib/issues,2012-11-07,2012-11-07,
novalue,l3kernel,The LaTeX3 Project,https://www.latex-project.org/latex3.html,https://github.com/latex3/latex3.git,https://github.com/latex3/latex3/issues,2018-05-12,2018-05-12,
+nwejm,nwejm,Denis Bitouzé,https://github.com/dbitouze/nwejm,git@github.com:dbitouze/nwejm.git,2020-05-13,2020-05-13,
ocgbase,ocgx2,Alexander Grahn,,https://gitlab.com/agrahn/ocgx2,https://gitlab.com/agrahn/ocgx2/issues,2016-02-26,2020-04-15,
ocgxii,ocgx2,Alexander Grahn,,https://gitlab.com/agrahn/ocgx2,https://gitlab.com/agrahn/ocgx2/issues,2016-02-26,2020-04-15,
one,l3kernel,The LaTeX3 Project,https://www.latex-project.org/latex3.html,https://github.com/latex3/latex3.git,https://github.com/latex3/latex3/issues,2018-05-12,2018-05-12,
diff --git a/Master/texmf-dist/doc/latex/l3kernel/l3prefixes.pdf b/Master/texmf-dist/doc/latex/l3kernel/l3prefixes.pdf
index fbf3f14164b..3b412e4338f 100644
--- a/Master/texmf-dist/doc/latex/l3kernel/l3prefixes.pdf
+++ b/Master/texmf-dist/doc/latex/l3kernel/l3prefixes.pdf
Binary files differ
diff --git a/Master/texmf-dist/doc/latex/l3kernel/l3styleguide.pdf b/Master/texmf-dist/doc/latex/l3kernel/l3styleguide.pdf
index eb0878701d2..caccebc3f6e 100644
--- a/Master/texmf-dist/doc/latex/l3kernel/l3styleguide.pdf
+++ b/Master/texmf-dist/doc/latex/l3kernel/l3styleguide.pdf
Binary files differ
diff --git a/Master/texmf-dist/doc/latex/l3kernel/l3styleguide.tex b/Master/texmf-dist/doc/latex/l3kernel/l3styleguide.tex
index 16d5983a046..0f041828962 100644
--- a/Master/texmf-dist/doc/latex/l3kernel/l3styleguide.tex
+++ b/Master/texmf-dist/doc/latex/l3kernel/l3styleguide.tex
@@ -32,7 +32,7 @@ The released version of this bundle is available from CTAN.
{latex-team@latex-project.org}%
}%
}
-\date{Released 2020-05-11}
+\date{Released 2020-05-14}
\begin{document}
diff --git a/Master/texmf-dist/doc/latex/l3kernel/l3syntax-changes.pdf b/Master/texmf-dist/doc/latex/l3kernel/l3syntax-changes.pdf
index 44c75ca2e30..5366e6446be 100644
--- a/Master/texmf-dist/doc/latex/l3kernel/l3syntax-changes.pdf
+++ b/Master/texmf-dist/doc/latex/l3kernel/l3syntax-changes.pdf
Binary files differ
diff --git a/Master/texmf-dist/doc/latex/l3kernel/l3syntax-changes.tex b/Master/texmf-dist/doc/latex/l3kernel/l3syntax-changes.tex
index 0bc6adc9ac4..c11fe2002fb 100644
--- a/Master/texmf-dist/doc/latex/l3kernel/l3syntax-changes.tex
+++ b/Master/texmf-dist/doc/latex/l3kernel/l3syntax-changes.tex
@@ -32,7 +32,7 @@ The released version of this bundle is available from CTAN.
{latex-team@latex-project.org}%
}%
}
-\date{Released 2020-05-11}
+\date{Released 2020-05-14}
\newcommand{\TF}{\textit{(TF)}}
diff --git a/Master/texmf-dist/doc/latex/l3kernel/l3term-glossary.pdf b/Master/texmf-dist/doc/latex/l3kernel/l3term-glossary.pdf
index 974430a84b7..06e770e2913 100644
--- a/Master/texmf-dist/doc/latex/l3kernel/l3term-glossary.pdf
+++ b/Master/texmf-dist/doc/latex/l3kernel/l3term-glossary.pdf
Binary files differ
diff --git a/Master/texmf-dist/doc/latex/l3kernel/l3term-glossary.tex b/Master/texmf-dist/doc/latex/l3kernel/l3term-glossary.tex
index eab4b9053c3..3e35a2e3b80 100644
--- a/Master/texmf-dist/doc/latex/l3kernel/l3term-glossary.tex
+++ b/Master/texmf-dist/doc/latex/l3kernel/l3term-glossary.tex
@@ -32,7 +32,7 @@ The released version of this bundle is available from CTAN.
{latex-team@latex-project.org}%
}%
}
-\date{Released 2020-05-11}
+\date{Released 2020-05-14}
\newcommand{\TF}{\textit{(TF)}}
diff --git a/Master/texmf-dist/doc/latex/l3kernel/source3.pdf b/Master/texmf-dist/doc/latex/l3kernel/source3.pdf
index 21358a14f78..af4dac1c7d4 100644
--- a/Master/texmf-dist/doc/latex/l3kernel/source3.pdf
+++ b/Master/texmf-dist/doc/latex/l3kernel/source3.pdf
Binary files differ
diff --git a/Master/texmf-dist/doc/latex/l3kernel/source3.tex b/Master/texmf-dist/doc/latex/l3kernel/source3.tex
index 91b33318e56..4209a7e724d 100644
--- a/Master/texmf-dist/doc/latex/l3kernel/source3.tex
+++ b/Master/texmf-dist/doc/latex/l3kernel/source3.tex
@@ -53,7 +53,7 @@ for those people who are interested.
{latex-team@latex-project.org}%
}%
}
-\date{Released 2020-05-11}
+\date{Released 2020-05-14}
\pagenumbering{roman}
\maketitle
diff --git a/Master/texmf-dist/doc/latex/l3packages/CHANGELOG.md b/Master/texmf-dist/doc/latex/l3packages/CHANGELOG.md
index 515f5d001b4..ee88f4780fa 100644
--- a/Master/texmf-dist/doc/latex/l3packages/CHANGELOG.md
+++ b/Master/texmf-dist/doc/latex/l3packages/CHANGELOG.md
@@ -7,6 +7,11 @@ this project uses date-based 'snapshot' version identifiers.
## [Unreleased]
+## [2020-05-14]
+
+### Changed
+- Internal packaging of `xparse` in advance of changes to the LaTeX2e kernel
+
## [2020-03-06]
### Added
@@ -92,7 +97,8 @@ this project uses date-based 'snapshot' version identifiers.
- Switch to ISO date format
- Improve cross-module use of internal functions
-[Unreleased]: https://github.com/latex3/latex3/compare/2020-03-06...HEAD
+[Unreleased]: https://github.com/latex3/latex3/compare/2020-05-14...HEAD
+[2020-05-14]: https://github.com/latex3/latex3/compare/2020-03-06...2020-05-14
[2020-03-06]: https://github.com/latex3/latex3/compare/2020-03-03...2020-03-06
[2020-03-03]: https://github.com/latex3/latex3/compare/2020-02-25...2020-03-03
[2020-02-25]: https://github.com/latex3/latex3/compare/2020-02-14...2020-02-25
diff --git a/Master/texmf-dist/doc/latex/l3packages/README.md b/Master/texmf-dist/doc/latex/l3packages/README.md
index dbfd91cf349..8f505b01411 100644
--- a/Master/texmf-dist/doc/latex/l3packages/README.md
+++ b/Master/texmf-dist/doc/latex/l3packages/README.md
@@ -1,7 +1,7 @@
LaTeX3 High-Level Concepts
==========================
-Release 2020-03-06
+Release 2020-05-14
Overview
--------
diff --git a/Master/texmf-dist/doc/latex/l3packages/l3keys2e/l3keys2e.pdf b/Master/texmf-dist/doc/latex/l3packages/l3keys2e/l3keys2e.pdf
index 497301bdf7f..0611a9b9799 100644
--- a/Master/texmf-dist/doc/latex/l3packages/l3keys2e/l3keys2e.pdf
+++ b/Master/texmf-dist/doc/latex/l3packages/l3keys2e/l3keys2e.pdf
Binary files differ
diff --git a/Master/texmf-dist/doc/latex/l3packages/xfp/xfp.pdf b/Master/texmf-dist/doc/latex/l3packages/xfp/xfp.pdf
index 2191564816a..96c91d897d2 100644
--- a/Master/texmf-dist/doc/latex/l3packages/xfp/xfp.pdf
+++ b/Master/texmf-dist/doc/latex/l3packages/xfp/xfp.pdf
Binary files differ
diff --git a/Master/texmf-dist/doc/latex/l3packages/xfrac/xfrac.pdf b/Master/texmf-dist/doc/latex/l3packages/xfrac/xfrac.pdf
index a6b5f6a7c9c..9454c240a2f 100644
--- a/Master/texmf-dist/doc/latex/l3packages/xfrac/xfrac.pdf
+++ b/Master/texmf-dist/doc/latex/l3packages/xfrac/xfrac.pdf
Binary files differ
diff --git a/Master/texmf-dist/doc/latex/l3packages/xparse/xparse.pdf b/Master/texmf-dist/doc/latex/l3packages/xparse/xparse.pdf
index 76fe65c72bb..7813fa35268 100644
--- a/Master/texmf-dist/doc/latex/l3packages/xparse/xparse.pdf
+++ b/Master/texmf-dist/doc/latex/l3packages/xparse/xparse.pdf
Binary files differ
diff --git a/Master/texmf-dist/doc/latex/l3packages/xtemplate/xtemplate.pdf b/Master/texmf-dist/doc/latex/l3packages/xtemplate/xtemplate.pdf
index 68bbd25f44b..e69b3a41429 100644
--- a/Master/texmf-dist/doc/latex/l3packages/xtemplate/xtemplate.pdf
+++ b/Master/texmf-dist/doc/latex/l3packages/xtemplate/xtemplate.pdf
Binary files differ
diff --git a/Master/texmf-dist/source/latex/l3kernel/expl3.dtx b/Master/texmf-dist/source/latex/l3kernel/expl3.dtx
index a24e520f458..c03cfc436e5 100644
--- a/Master/texmf-dist/source/latex/l3kernel/expl3.dtx
+++ b/Master/texmf-dist/source/latex/l3kernel/expl3.dtx
@@ -24,7 +24,7 @@
%
%<*driver|generic|package|2ekernel>
%</driver|generic|package|2ekernel>
-\def\ExplFileDate{2020-05-11}%
+\def\ExplFileDate{2020-05-14}%
%<*driver>
\documentclass[full]{l3doc}
\usepackage{graphicx}
@@ -51,7 +51,7 @@
% }^^A
% }
%
-% \date{Released 2020-05-11}
+% \date{Released 2020-05-14}
%
% \maketitle
%
diff --git a/Master/texmf-dist/source/latex/l3kernel/l3alloc.dtx b/Master/texmf-dist/source/latex/l3kernel/l3alloc.dtx
index 188477adcf5..4e3ffdbe20f 100644
--- a/Master/texmf-dist/source/latex/l3kernel/l3alloc.dtx
+++ b/Master/texmf-dist/source/latex/l3kernel/l3alloc.dtx
@@ -43,7 +43,7 @@
% }^^A
% }
%
-% \date{Released 2020-05-11}
+% \date{Released 2020-05-14}
%
% \maketitle
%
diff --git a/Master/texmf-dist/source/latex/l3kernel/l3basics.dtx b/Master/texmf-dist/source/latex/l3kernel/l3basics.dtx
index 22b7a75d15d..8069dbafa87 100644
--- a/Master/texmf-dist/source/latex/l3kernel/l3basics.dtx
+++ b/Master/texmf-dist/source/latex/l3kernel/l3basics.dtx
@@ -43,7 +43,7 @@
% }^^A
% }
%
-% \date{Released 2020-05-11}
+% \date{Released 2020-05-14}
%
% \maketitle
%
diff --git a/Master/texmf-dist/source/latex/l3kernel/l3bootstrap.dtx b/Master/texmf-dist/source/latex/l3kernel/l3bootstrap.dtx
index 4ff6267be1c..88682ead646 100644
--- a/Master/texmf-dist/source/latex/l3kernel/l3bootstrap.dtx
+++ b/Master/texmf-dist/source/latex/l3kernel/l3bootstrap.dtx
@@ -43,7 +43,7 @@
% }^^A
% }
%
-% \date{Released 2020-05-11}
+% \date{Released 2020-05-14}
%
% \maketitle
%
diff --git a/Master/texmf-dist/source/latex/l3kernel/l3box.dtx b/Master/texmf-dist/source/latex/l3kernel/l3box.dtx
index 7c6b12dd787..9279b3a1da4 100644
--- a/Master/texmf-dist/source/latex/l3kernel/l3box.dtx
+++ b/Master/texmf-dist/source/latex/l3kernel/l3box.dtx
@@ -43,7 +43,7 @@
% }^^A
% }
%
-% \date{Released 2020-05-11}
+% \date{Released 2020-05-14}
%
% \maketitle
%
diff --git a/Master/texmf-dist/source/latex/l3kernel/l3candidates.dtx b/Master/texmf-dist/source/latex/l3kernel/l3candidates.dtx
index c97fb26e258..90d433dcd94 100644
--- a/Master/texmf-dist/source/latex/l3kernel/l3candidates.dtx
+++ b/Master/texmf-dist/source/latex/l3kernel/l3candidates.dtx
@@ -44,7 +44,7 @@
% }^^A
% }
%
-% \date{Released 2020-05-11}
+% \date{Released 2020-05-14}
%
% \maketitle
%
diff --git a/Master/texmf-dist/source/latex/l3kernel/l3clist.dtx b/Master/texmf-dist/source/latex/l3kernel/l3clist.dtx
index 0b011f80e0e..b6c9390ceef 100644
--- a/Master/texmf-dist/source/latex/l3kernel/l3clist.dtx
+++ b/Master/texmf-dist/source/latex/l3kernel/l3clist.dtx
@@ -44,7 +44,7 @@
% }^^A
% }
%
-% \date{Released 2020-05-11}
+% \date{Released 2020-05-14}
%
% \maketitle
%
diff --git a/Master/texmf-dist/source/latex/l3kernel/l3coffins.dtx b/Master/texmf-dist/source/latex/l3kernel/l3coffins.dtx
index 47fca974655..2dd3f49c121 100644
--- a/Master/texmf-dist/source/latex/l3kernel/l3coffins.dtx
+++ b/Master/texmf-dist/source/latex/l3kernel/l3coffins.dtx
@@ -43,7 +43,7 @@
% }^^A
% }
%
-% \date{Released 2020-05-11}
+% \date{Released 2020-05-14}
%
% \maketitle
%
diff --git a/Master/texmf-dist/source/latex/l3kernel/l3color-base.dtx b/Master/texmf-dist/source/latex/l3kernel/l3color-base.dtx
index 0555edc19cb..5f0d01d4207 100644
--- a/Master/texmf-dist/source/latex/l3kernel/l3color-base.dtx
+++ b/Master/texmf-dist/source/latex/l3kernel/l3color-base.dtx
@@ -43,7 +43,7 @@
% }^^A
% }
%
-% \date{Released 2020-05-11}
+% \date{Released 2020-05-14}
%
% \maketitle
%
diff --git a/Master/texmf-dist/source/latex/l3kernel/l3debug.dtx b/Master/texmf-dist/source/latex/l3kernel/l3debug.dtx
index df79d6a031d..d3be8e5fd03 100644
--- a/Master/texmf-dist/source/latex/l3kernel/l3debug.dtx
+++ b/Master/texmf-dist/source/latex/l3kernel/l3debug.dtx
@@ -43,7 +43,7 @@
% }^^A
% }
%
-% \date{Released 2020-05-11}
+% \date{Released 2020-05-14}
%
% \maketitle
%
diff --git a/Master/texmf-dist/source/latex/l3kernel/l3deprecation.dtx b/Master/texmf-dist/source/latex/l3kernel/l3deprecation.dtx
index f84e9faea3a..3143cbcd9f1 100644
--- a/Master/texmf-dist/source/latex/l3kernel/l3deprecation.dtx
+++ b/Master/texmf-dist/source/latex/l3kernel/l3deprecation.dtx
@@ -43,7 +43,7 @@
% }^^A
% }
%
-% \date{Released 2020-05-11}
+% \date{Released 2020-05-14}
%
% \maketitle
%
diff --git a/Master/texmf-dist/source/latex/l3kernel/l3doc.dtx b/Master/texmf-dist/source/latex/l3kernel/l3doc.dtx
index 9ef8771afb4..1f9bb203941 100644
--- a/Master/texmf-dist/source/latex/l3kernel/l3doc.dtx
+++ b/Master/texmf-dist/source/latex/l3kernel/l3doc.dtx
@@ -79,7 +79,7 @@ and all files in that bundle must be distributed together.
%
% \title{The \cls{l3doc} class}
% \author{\Team}
-% \date{Released 2020-05-11}
+% \date{Released 2020-05-14}
% \maketitle
% \tableofcontents
%
diff --git a/Master/texmf-dist/source/latex/l3kernel/l3docstrip.dtx b/Master/texmf-dist/source/latex/l3kernel/l3docstrip.dtx
index 044e3fbab5f..8177c56ddce 100644
--- a/Master/texmf-dist/source/latex/l3kernel/l3docstrip.dtx
+++ b/Master/texmf-dist/source/latex/l3kernel/l3docstrip.dtx
@@ -63,7 +63,7 @@
% }^^A
% }
%
-% \date{Released 2020-05-11}
+% \date{Released 2020-05-14}
%
% \maketitle
%
diff --git a/Master/texmf-dist/source/latex/l3kernel/l3expan.dtx b/Master/texmf-dist/source/latex/l3kernel/l3expan.dtx
index 0841f43fc44..6357eb73174 100644
--- a/Master/texmf-dist/source/latex/l3kernel/l3expan.dtx
+++ b/Master/texmf-dist/source/latex/l3kernel/l3expan.dtx
@@ -43,7 +43,7 @@
% }^^A
% }
%
-% \date{Released 2020-05-11}
+% \date{Released 2020-05-14}
%
% \maketitle
%
diff --git a/Master/texmf-dist/source/latex/l3kernel/l3file.dtx b/Master/texmf-dist/source/latex/l3kernel/l3file.dtx
index c816d771fbe..2aba70b29ed 100644
--- a/Master/texmf-dist/source/latex/l3kernel/l3file.dtx
+++ b/Master/texmf-dist/source/latex/l3kernel/l3file.dtx
@@ -44,7 +44,7 @@
% }^^A
% }
%
-% \date{Released 2020-05-11}
+% \date{Released 2020-05-14}
%
% \maketitle
%
diff --git a/Master/texmf-dist/source/latex/l3kernel/l3final.dtx b/Master/texmf-dist/source/latex/l3kernel/l3final.dtx
index d48aac03f51..79b816bfd8a 100644
--- a/Master/texmf-dist/source/latex/l3kernel/l3final.dtx
+++ b/Master/texmf-dist/source/latex/l3kernel/l3final.dtx
@@ -43,7 +43,7 @@
% }^^A
% }
%
-% \date{Released 2020-05-11}
+% \date{Released 2020-05-14}
%
% \maketitle
%
diff --git a/Master/texmf-dist/source/latex/l3kernel/l3flag.dtx b/Master/texmf-dist/source/latex/l3kernel/l3flag.dtx
index 7a76d293869..301f78a3407 100644
--- a/Master/texmf-dist/source/latex/l3kernel/l3flag.dtx
+++ b/Master/texmf-dist/source/latex/l3kernel/l3flag.dtx
@@ -43,7 +43,7 @@
% }^^A
% }
%
-% \date{Released 2020-05-11}
+% \date{Released 2020-05-14}
%
% \maketitle
%
diff --git a/Master/texmf-dist/source/latex/l3kernel/l3fp-assign.dtx b/Master/texmf-dist/source/latex/l3kernel/l3fp-assign.dtx
index 725abc23b9e..64e67f8fad0 100644
--- a/Master/texmf-dist/source/latex/l3kernel/l3fp-assign.dtx
+++ b/Master/texmf-dist/source/latex/l3kernel/l3fp-assign.dtx
@@ -40,7 +40,7 @@
% {latex-team@latex-project.org}^^A
% }^^A
% }
-% \date{Released 2020-05-11}
+% \date{Released 2020-05-14}
% \maketitle
%
% \begin{documentation}
diff --git a/Master/texmf-dist/source/latex/l3kernel/l3fp-aux.dtx b/Master/texmf-dist/source/latex/l3kernel/l3fp-aux.dtx
index 02817722757..85a31450c94 100644
--- a/Master/texmf-dist/source/latex/l3kernel/l3fp-aux.dtx
+++ b/Master/texmf-dist/source/latex/l3kernel/l3fp-aux.dtx
@@ -43,7 +43,7 @@
% }^^A
% }
%
-% \date{Released 2020-05-11}
+% \date{Released 2020-05-14}
%
% \maketitle
%
diff --git a/Master/texmf-dist/source/latex/l3kernel/l3fp-basics.dtx b/Master/texmf-dist/source/latex/l3kernel/l3fp-basics.dtx
index 55823ba7fb2..b634f3a949a 100644
--- a/Master/texmf-dist/source/latex/l3kernel/l3fp-basics.dtx
+++ b/Master/texmf-dist/source/latex/l3kernel/l3fp-basics.dtx
@@ -40,7 +40,7 @@
% {latex-team@latex-project.org}^^A
% }^^A
% }
-% \date{Released 2020-05-11}
+% \date{Released 2020-05-14}
%
% \maketitle
%
diff --git a/Master/texmf-dist/source/latex/l3kernel/l3fp-convert.dtx b/Master/texmf-dist/source/latex/l3kernel/l3fp-convert.dtx
index fc629937c47..9ede33c3780 100644
--- a/Master/texmf-dist/source/latex/l3kernel/l3fp-convert.dtx
+++ b/Master/texmf-dist/source/latex/l3kernel/l3fp-convert.dtx
@@ -43,7 +43,7 @@
% }^^A
% }
%
-% \date{Released 2020-05-11}
+% \date{Released 2020-05-14}
%
% \maketitle
%
diff --git a/Master/texmf-dist/source/latex/l3kernel/l3fp-expo.dtx b/Master/texmf-dist/source/latex/l3kernel/l3fp-expo.dtx
index a1defe98894..8f2c090d5b0 100644
--- a/Master/texmf-dist/source/latex/l3kernel/l3fp-expo.dtx
+++ b/Master/texmf-dist/source/latex/l3kernel/l3fp-expo.dtx
@@ -40,7 +40,7 @@
% {latex-team@latex-project.org}^^A
% }^^A
% }
-% \date{Released 2020-05-11}
+% \date{Released 2020-05-14}
%
% \maketitle
%
diff --git a/Master/texmf-dist/source/latex/l3kernel/l3fp-extended.dtx b/Master/texmf-dist/source/latex/l3kernel/l3fp-extended.dtx
index 8904c442005..28b2eaca4fa 100644
--- a/Master/texmf-dist/source/latex/l3kernel/l3fp-extended.dtx
+++ b/Master/texmf-dist/source/latex/l3kernel/l3fp-extended.dtx
@@ -40,7 +40,7 @@
% {latex-team@latex-project.org}^^A
% }^^A
% }
-% \date{Released 2020-05-11}
+% \date{Released 2020-05-14}
%
% \maketitle
%
diff --git a/Master/texmf-dist/source/latex/l3kernel/l3fp-logic.dtx b/Master/texmf-dist/source/latex/l3kernel/l3fp-logic.dtx
index a503e3a3d49..a76ba25fb4b 100644
--- a/Master/texmf-dist/source/latex/l3kernel/l3fp-logic.dtx
+++ b/Master/texmf-dist/source/latex/l3kernel/l3fp-logic.dtx
@@ -40,7 +40,7 @@
% {latex-team@latex-project.org}^^A
% }^^A
% }
-% \date{Released 2020-05-11}
+% \date{Released 2020-05-14}
%
% \maketitle
%
diff --git a/Master/texmf-dist/source/latex/l3kernel/l3fp-parse.dtx b/Master/texmf-dist/source/latex/l3kernel/l3fp-parse.dtx
index 978d4dfe7f3..bc0a4c1e64f 100644
--- a/Master/texmf-dist/source/latex/l3kernel/l3fp-parse.dtx
+++ b/Master/texmf-dist/source/latex/l3kernel/l3fp-parse.dtx
@@ -40,7 +40,7 @@
% {latex-team@latex-project.org}^^A
% }^^A
% }
-% \date{Released 2020-05-11}
+% \date{Released 2020-05-14}
%
% \maketitle
%
diff --git a/Master/texmf-dist/source/latex/l3kernel/l3fp-random.dtx b/Master/texmf-dist/source/latex/l3kernel/l3fp-random.dtx
index 11bf7d311d1..61e8d09b8fe 100644
--- a/Master/texmf-dist/source/latex/l3kernel/l3fp-random.dtx
+++ b/Master/texmf-dist/source/latex/l3kernel/l3fp-random.dtx
@@ -40,7 +40,7 @@
% {latex-team@latex-project.org}^^A
% }^^A
% }
-% \date{Released 2020-05-11}
+% \date{Released 2020-05-14}
%
% \maketitle
%
diff --git a/Master/texmf-dist/source/latex/l3kernel/l3fp-round.dtx b/Master/texmf-dist/source/latex/l3kernel/l3fp-round.dtx
index a5b0bc64859..0edd5bf20c1 100644
--- a/Master/texmf-dist/source/latex/l3kernel/l3fp-round.dtx
+++ b/Master/texmf-dist/source/latex/l3kernel/l3fp-round.dtx
@@ -43,7 +43,7 @@
% }^^A
% }
%
-% \date{Released 2020-05-11}
+% \date{Released 2020-05-14}
%
% \maketitle
%
diff --git a/Master/texmf-dist/source/latex/l3kernel/l3fp-traps.dtx b/Master/texmf-dist/source/latex/l3kernel/l3fp-traps.dtx
index 51d25a090ee..093fdccffe0 100644
--- a/Master/texmf-dist/source/latex/l3kernel/l3fp-traps.dtx
+++ b/Master/texmf-dist/source/latex/l3kernel/l3fp-traps.dtx
@@ -40,7 +40,7 @@
% {latex-team@latex-project.org}^^A
% }^^A
% }
-% \date{Released 2020-05-11}
+% \date{Released 2020-05-14}
% \maketitle
%
% \begin{documentation}
diff --git a/Master/texmf-dist/source/latex/l3kernel/l3fp-trig.dtx b/Master/texmf-dist/source/latex/l3kernel/l3fp-trig.dtx
index 156485e6286..1d4ce7f6a68 100644
--- a/Master/texmf-dist/source/latex/l3kernel/l3fp-trig.dtx
+++ b/Master/texmf-dist/source/latex/l3kernel/l3fp-trig.dtx
@@ -40,7 +40,7 @@
% {latex-team@latex-project.org}^^A
% }^^A
% }
-% \date{Released 2020-05-11}
+% \date{Released 2020-05-14}
%
% \maketitle
%
diff --git a/Master/texmf-dist/source/latex/l3kernel/l3fp.dtx b/Master/texmf-dist/source/latex/l3kernel/l3fp.dtx
index f9bcbee4677..4dd9a6815c1 100644
--- a/Master/texmf-dist/source/latex/l3kernel/l3fp.dtx
+++ b/Master/texmf-dist/source/latex/l3kernel/l3fp.dtx
@@ -49,7 +49,7 @@
% }^^A
% }
%
-% \date{Released 2020-05-11}
+% \date{Released 2020-05-14}
%
% \maketitle
%
diff --git a/Master/texmf-dist/source/latex/l3kernel/l3fparray.dtx b/Master/texmf-dist/source/latex/l3kernel/l3fparray.dtx
index d41c366b739..9295a0d05a3 100644
--- a/Master/texmf-dist/source/latex/l3kernel/l3fparray.dtx
+++ b/Master/texmf-dist/source/latex/l3kernel/l3fparray.dtx
@@ -44,7 +44,7 @@
% }^^A
% }
%
-% \date{Released 2020-05-11}
+% \date{Released 2020-05-14}
%
% \maketitle
%
diff --git a/Master/texmf-dist/source/latex/l3kernel/l3int.dtx b/Master/texmf-dist/source/latex/l3kernel/l3int.dtx
index faab276e44a..6b58e379da8 100644
--- a/Master/texmf-dist/source/latex/l3kernel/l3int.dtx
+++ b/Master/texmf-dist/source/latex/l3kernel/l3int.dtx
@@ -43,7 +43,7 @@
% }^^A
% }
%
-% \date{Released 2020-05-11}
+% \date{Released 2020-05-14}
%
% \maketitle
%
diff --git a/Master/texmf-dist/source/latex/l3kernel/l3intarray.dtx b/Master/texmf-dist/source/latex/l3kernel/l3intarray.dtx
index 1c68482f551..c8ea3e31721 100644
--- a/Master/texmf-dist/source/latex/l3kernel/l3intarray.dtx
+++ b/Master/texmf-dist/source/latex/l3kernel/l3intarray.dtx
@@ -44,7 +44,7 @@
% }^^A
% }
%
-% \date{Released 2020-05-11}
+% \date{Released 2020-05-14}
%
% \maketitle
%
diff --git a/Master/texmf-dist/source/latex/l3kernel/l3kernel-functions.dtx b/Master/texmf-dist/source/latex/l3kernel/l3kernel-functions.dtx
index d5cc6170ad4..52dd498f571 100644
--- a/Master/texmf-dist/source/latex/l3kernel/l3kernel-functions.dtx
+++ b/Master/texmf-dist/source/latex/l3kernel/l3kernel-functions.dtx
@@ -43,7 +43,7 @@
% }^^A
% }
%
-% \date{Released 2020-05-11}
+% \date{Released 2020-05-14}
%
% \maketitle
%
diff --git a/Master/texmf-dist/source/latex/l3kernel/l3keys.dtx b/Master/texmf-dist/source/latex/l3kernel/l3keys.dtx
index b3630af0b16..621f3776ded 100644
--- a/Master/texmf-dist/source/latex/l3kernel/l3keys.dtx
+++ b/Master/texmf-dist/source/latex/l3kernel/l3keys.dtx
@@ -43,7 +43,7 @@
% }^^A
% }
%
-% \date{Released 2020-05-11}
+% \date{Released 2020-05-14}
%
% \maketitle
%
@@ -939,13 +939,13 @@
%
% \subsection{Low-level interface}
%
-% The low-level key parser is based heavily on \pkg{keyval}, but with a number
-% of additional \enquote{safety} requirements and with the idea that the
-% parsed list of key--value pairs can be processed in a variety of ways.
-% The net result is that this code needs around twice the amount of time
-% as \pkg{keyval} to parse the same list of keys. To optimise speed as far
-% as reasonably practical, a number of lower-level approaches are taken
-% rather than using the higher-level \pkg{expl3} interfaces.
+% The low-level key parser's implementation is based heavily on \pkg{expkv}.
+% Compared to \pkg{keyval} it adds a number of additional \enquote{safety}
+% requirements and allows to process the parsed list of key--value pairs in a
+% variety of ways. The net result is that this code needs around one and a half
+% the amount of time as \pkg{keyval} to parse the same list of keys. To optimise
+% speed as far as reasonably practical, a number of lower-level approaches are
+% taken rather than using the higher-level \pkg{expl3} interfaces.
%
% \begin{macrocode}
%<@@=keyval>
@@ -970,9 +970,9 @@
% \end{macrocode}
%
% \begin{macro}[EXP]{\keyval_parse:NNn}
-% The main function starts the first of two input loops. The outer loop splits
-% the key--value list at active commas, the inner loop will do so at other
-% commas. The use of \cs{s_@@_mark} here prevents loss of braces from the key
+% The main function starts the first of two loops. The outer loop splits the
+% key--value list at active commas, the inner loop will do so at other commas.
+% The use of \cs{s_@@_mark} here prevents loss of braces from the key
% argument.
% \begin{macrocode}
\cs_new:Npn \keyval_parse:NNn ##1 ##2 ##3
@@ -982,157 +982,267 @@
%
% \begin{macro}[EXP]{\@@_loop_active:NNw}
% First a fast test for the end of the loop is done, it'll gobble everything
-% up to an \cs{s_@@_mark} immediately followed by an \cs{s_@@_tail}. The loop
-% ending macro will gobble everything to the last \cs{s_@@_mark} in this
-% definition.
+% up to a \cs{s_@@_tail}. The loop ending macro will gobble everything to the
+% last \cs{s_@@_mark} in this definition.
% If the end isn't reached yet, start the second loop splitting at other
-% comments, and after that one iterate the current loop.
+% commas, and after that one iterate the current loop.
% \begin{macrocode}
\cs_new:Npn \@@_loop_active:NNw ##1 ##2 ##3 #1
{
\@@_if_recursion_tail:w ##3
- \@@_end_loop_active:w \s_@@_mark \s_@@_tail
+ \@@_end_loop_active:w \s_@@_tail
\@@_loop_other:NNw ##1 ##2 ##3 , \s_@@_tail ,
\@@_loop_active:NNw ##1 ##2 \s_@@_mark
}
% \end{macrocode}
% \end{macro}
%
+% \begin{macro}[EXP]{\@@_split_other:w, \@@_split_active:w}
+% These two macros allow to split at the first equals sign of category 12 or
+% 13. At the same time they also execute branching by inserting the first
+% token following \cs{s_@@_mark} that followed the equals sign. Hence they
+% also test for the presence of such an equals sign simultaneously.
+% \begin{macrocode}
+ \cs_new:Npn \@@_split_other:w ##1 = ##2 \s_@@_mark ##3 ##4 \s_@@_stop
+ { ##3 ##1 \s_@@_stop \s_@@_mark ##2 }
+ \cs_new:Npn \@@_split_active:w ##1 #2 ##2 \s_@@_mark ##3 ##4 \s_@@_stop
+ { ##3 ##1 \s_@@_stop \s_@@_mark ##2 }
+% \end{macrocode}
+% \end{macro}
+%
% \begin{macro}[EXP]{\@@_loop_other:NNw}
% The second loop uses the same test for its end as the first loop, next it
-% tests whether there are other or active equals signs, throwing an error if
-% there are both. If there are none, test whether the argument is blank or is
-% a single key. If there are only active equals signs split at those, else
-% split at others. Finally, iterate the loop.
+% splits at the first active equals sign using \cs{@@_split_active:w}. The
+% \cs{s_@@_nil} prevents accidental brace stripping and acts as a delimiter in
+% the next steps. First testing for an active equals sign will reduce the
+% number of necessary expansion steps for the expected average use case of
+% other equals signs and hence perform better on average.
% \begin{macrocode}
\cs_new:Npn \@@_loop_other:NNw ##1 ##2 ##3 ,
{
\@@_if_recursion_tail:w ##3
- \@@_end_loop_other:w \s_@@_mark \s_@@_tail
- \@@_if_has_equal_other:w ##3 = \s_@@_stop
- \@@_has_false:w \s_@@_mark \s_@@_stop \use_i:nn
- {
- \@@_if_has_equal_active:w ##3 #2 \s_@@_stop
- \@@_has_false:w \s_@@_mark \s_@@_stop \use_i:nn
- \@@_misplaced_equal_error:
- { \@@_split_other:w ##3 = \s_@@_stop ##2 }
- }
- {
- \@@_if_has_equal_active:w ##3 #2 \s_@@_stop
- \@@_has_false:w \s_@@_mark \s_@@_stop \use_i:nn
- { \@@_split_active:w ##3 #2 \s_@@_stop ##2 }
- {
- \@@_if_blank:w ##3 \s_@@_nil \s_@@_stop
- \@@_blank_true:w \s_@@_mark \s_@@_stop \use:n
- { \@@_trim:nN { ##3 } \@@_key:nN ##1 }
- }
- }
+ \@@_end_loop_other:w \s_@@_tail
+ \@@_split_active:w ##3 \s_@@_nil
+ \s_@@_mark \@@_split_active_auxi:w
+ #2 \s_@@_mark \@@_clean_up_active:w
+ \s_@@_stop
+ ##1 ##2
\@@_loop_other:NNw ##1 ##2 \s_@@_mark
}
% \end{macrocode}
% \end{macro}
%
-% \begin{macro}[EXP]{\@@_split_active:w}
-% \begin{macro}[EXP]{\@@_split_active:nw}
-% Splits at the first active equals sign and trims the key. Next test whether
-% there are any more valid split points, if so throw an error and gobble the
-% remaining \meta{function_2}, which will not yet be gobbled. If there was
-% only one active equals sign start trimming the spaces off the value and give
-% control to \cs[no-index]{@@_key_val:nnN}.
+% \begin{macro}[EXP]{\@@_split_active_auxi:w}
+% \begin{macro}[EXP]{\@@_split_active_auxii:w}
+% \begin{macro}[EXP]{\@@_split_active_auxiii:w}
+% \begin{macro}[EXP]{\@@_split_active_auxiv:w}
+% \begin{macro}[EXP]{\@@_split_active_auxv:w}
+% After \cs{@@_split_active:w} the following will only be called if there was
+% at least one active equals sign in the current key--value pair. Therefore
+% this is the execution branch for a key--value pair with an active equals
+% sign. |##1| will be everything up to the first active equals sign. First it
+% tests for other equals signs in the key name, which will eventually throw an
+% error via \cs{@@_misplaced_equal_after_active_error:w}. If none was found we
+% forward the key to \cs{@@_split_active_auxii:w}.
+% \begin{macrocode}
+ \cs_new:Npn \@@_split_active_auxi:w ##1 \s_@@_stop
+ {
+ \@@_split_other:w ##1 \s_@@_nil
+ \s_@@_mark \@@_misplaced_equal_after_active_error:w
+ = \s_@@_mark \@@_split_active_auxii:w
+ \s_@@_stop
+ }
+% \end{macrocode}
+% \cs{@@_split_active_auxii:w} gets the correct key name with a leading
+% \cs{s_@@_mark} as |##1|. It has to sanitise the remainder of the previous
+% test and trims the key name which will be forwarded to
+% \cs{@@_split_active_auxiii:w}.
+% \begin{macrocode}
+ \cs_new:Npn \@@_split_active_auxii:w
+ ##1 \s_@@_nil \s_@@_mark \@@_misplaced_equal_after_active_error:w
+ \s_@@_stop \s_@@_mark
+ { \@@_trim:nN { ##1 } \@@_split_active_auxiii:w }
+% \end{macrocode}
+% Next we test for a misplaced active equals sign in the value, if none is
+% found \cs{@@_split_active_auxiv:w} will be called.
+% \begin{macrocode}
+ \cs_new:Npn \@@_split_active_auxiii:w ##1 ##2 \s_@@_nil
+ {
+ \@@_split_active:w ##2 \s_@@_nil
+ \s_@@_mark \@@_misplaced_equal_in_split_error:w
+ #2 \s_@@_mark \@@_split_active_auxiv:w
+ \s_@@_stop
+ { ##1 }
+ }
+% \end{macrocode}
+% This runs the last test after sanitising the remainder of the previous one.
+% This time test for a misplaced equals sign of category 12 in the value.
+% Finally the last auxiliary macro will be called.
% \begin{macrocode}
- \cs_new:Npn \@@_split_active:w ##1 #2
- { \@@_trim:nN { ##1 } \@@_split_active:nw \s_@@_mark }
- \cs_new:Npn \@@_split_active:nw ##1 ##2 #2 ##3 \s_@@_stop
+ \cs_new:Npn \@@_split_active_auxiv:w
+ ##1 \s_@@_nil \s_@@_mark \@@_misplaced_equal_in_split_error:w
+ \s_@@_stop \s_@@_mark
{
- \@@_if_empty:w \s_@@_mark ##3 \s_@@_stop
- \@@_has_false:w \s_@@_mark \s_@@_stop \use_i:nn
- { \@@_misplaced_equal_error: \use_none:n }
- { \@@_trim:nN { ##2 } \@@_key_val:nnN { ##1 } }
+ \@@_split_other:w ##1 \s_@@_nil
+ \s_@@_mark \@@_misplaced_equal_in_split_error:w
+ = \s_@@_mark \@@_split_active_auxv:w
+ \s_@@_stop
}
% \end{macrocode}
+% This last macro in this execution branch sanitises the last test, trims the
+% value and passes it to \cs{@@_pair:nnNN}.
+% \begin{macrocode}
+ \cs_new:Npn \@@_split_active_auxv:w
+ ##1 \s_@@_nil \s_@@_mark \@@_misplaced_equal_in_split_error:w
+ \s_@@_stop \s_@@_mark
+ { \@@_trim:nN { ##1 } \@@_pair:nnNN }
+% \end{macrocode}
+% \end{macro}
+% \end{macro}
+% \end{macro}
% \end{macro}
% \end{macro}
%
-% \begin{macro}[EXP]{\@@_if_has_equal_active:w}
-% The test for an active equals sign just gobbles tokens until the first
-% active equals sign and then runs the test for an empty argument.
+% \begin{macro}[EXP]{\@@_clean_up_active:w}
+% The following is the branch taken if the key--value pair doesn't contain an
+% active equals sign. The remainder of that test will be cleaned up by
+% \cs{@@_clean_up_active:w} which will then split at an equals sign of
+% category other.
% \begin{macrocode}
- \cs_new:Npn \@@_if_has_equal_active:w ##1 #2
- { \@@_if_empty:w \s_@@_mark }
+ \cs_new:Npn \@@_clean_up_active:w
+ ##1 \s_@@_nil \s_@@_mark \@@_split_active_auxi:w \s_@@_stop \s_@@_mark
+ {
+ \@@_split_other:w ##1 \s_@@_nil
+ \s_@@_mark \@@_split_other_auxi:w
+ = \s_@@_mark \@@_clean_up_other:w
+ \s_@@_stop
+ }
% \end{macrocode}
% \end{macro}
%
-% We're done with the macros which need active equals signs or commas in their
-% definition, so we can end that scope and call the temporary macro which will
-% do the definitions.
+% \begin{macro}[EXP]{\@@_split_other_auxi:w}
+% \begin{macro}[EXP]{\@@_split_other_auxii:w}
+% \begin{macro}[EXP]{\@@_split_other_auxiii:w}
+% This is executed if the key--value pair doesn't contain an active equals
+% sign but at least one other. |##1| of \cs{@@_split_other_auxi:w} will
+% contain the complete key name, which is trimmed and forwarded to the next
+% auxiliary macro.
% \begin{macrocode}
- }
- \char_set_catcode_active:n { `\, }
- \char_set_catcode_active:n { `\= }
- \@@_tmp:NN , =
-\group_end:
+ \cs_new:Npn \@@_split_other_auxi:w ##1 \s_@@_stop
+ { \@@_trim:nN { ##1 } \@@_split_other_auxii:w }
+% \end{macrocode}
+% We know that the value doesn't contain misplaced active equals signs but we
+% have to test for others.
+% \begin{macrocode}
+ \cs_new:Npn \@@_split_other_auxii:w ##1 ##2 \s_@@_nil
+ {
+ \@@_split_other:w ##2 \s_@@_nil
+ \s_@@_mark \@@_misplaced_equal_in_split_error:w
+ = \s_@@_mark \@@_split_other_auxiii:w
+ \s_@@_stop
+ { ##1 }
+ }
+% \end{macrocode}
+% \cs{@@_split_other_auxiii:w} sanitises the test for other equals signs,
+% trims the value and forwards it to \cs{@@_pair:nnNN}.
+% \begin{macrocode}
+ \cs_new:Npn \@@_split_other_auxiii:w
+ ##1 \s_@@_nil \s_@@_mark \@@_misplaced_equal_in_split_error:w
+ \s_@@_stop \s_@@_mark
+ { \@@_trim:nN { ##1 } \@@_pair:nnNN }
% \end{macrocode}
+% \end{macro}
+% \end{macro}
+% \end{macro}
%
-% \begin{macro}[EXP]{\@@_end_loop_active:w,\@@_end_loop_other:w}
-% Both of these macros just have to gobble a few tokens to remove the reminder
-% of the loops current iteration. We do this in a pretty static manner,
-% explicitly stating every token we know beforehand because this is slightly
-% faster.
+% \begin{macro}[EXP]{\@@_clean_up_other:w}
+% \cs{@@_clean_up_other:w} is the last branch that might exist. It is called
+% if no equals sign was found, hence the only possibilities left are a blank
+% list element, which is to be skipped, or a lonely key. If it's no empty list
+% element this will trim the key name and forward it to \cs{@@_key:nNN}.
% \begin{macrocode}
-\cs_new:Npn \@@_end_loop_active:w
- \s_@@_mark \s_@@_tail
- \@@_loop_other:NNw #1 , \s_@@_tail ,
- \@@_loop_active:NNw #2 \s_@@_mark
- { }
-\cs_new:Npn \@@_end_loop_other:w
- \s_@@_mark \s_@@_tail
- \@@_if_has_equal_other:w #1 = \s_@@_stop
- \@@_has_false:w \s_@@_mark \s_@@_stop \use_i:nn
- #2
- \@@_loop_other:NNw #3 \s_@@_mark
- { }
+ \cs_new:Npn \@@_clean_up_other:w
+ ##1 \s_@@_nil \s_@@_mark \@@_split_other_auxi:w \s_@@_stop \s_@@_mark
+ {
+ \@@_if_blank:w ##1 \s_@@_nil \s_@@_stop \@@_blank_true:w
+ \s_@@_mark \s_@@_stop \use:n
+ { \@@_trim:nN { ##1 } \@@_key:nNN }
+ }
% \end{macrocode}
% \end{macro}
%
-% \begin{macro}[EXP]{\@@_split_other:w}
-% \begin{macro}[EXP]{\@@_split_other:nw}
-% These work exactly as \cs[no-index]{@@_split_active:wN}, just for
-% equals signs of category other.
+% \begin{macro}[EXP]{\@@_misplaced_equal_after_active_error:w}
+% \begin{macro}[EXP]{\@@_misplaced_equal_in_split_error:w}
+% All these two macros do is gobble the remainder of the current other loop
+% execution and throw an error.
% \begin{macrocode}
-\cs_new:Npn \@@_split_other:w #1 =
- { \@@_trim:nN { #1 } \@@_split_other:nw \s_@@_mark }
-\cs_new:Npn \@@_split_other:nw #1 #2 = #3 \s_@@_stop
- {
- \@@_if_empty:w \s_@@_mark #3 \s_@@_stop
- \@@_has_false:w \s_@@_mark \s_@@_stop \use_i:nn
- { \@@_misplaced_equal_error: \use_none:n }
- { \@@_trim:nN { #2 } \@@_key_val:nnN { #1 } }
- }
+ \cs_new:Npn \@@_misplaced_equal_after_active_error:w
+ \s_@@_mark ##1 \s_@@_stop \s_@@_mark ##2 \s_@@_nil
+ \s_@@_mark ##3 \s_@@_nil ##4 ##5
+ {
+ \__kernel_msg_expandable_error:nn
+ { kernel } { misplaced-equals-sign }
+ }
+ \cs_new:Npn \@@_misplaced_equal_in_split_error:w
+ \s_@@_mark ##1 \s_@@_stop \s_@@_mark ##2 \s_@@_nil
+ ##3 ##4 ##5
+ {
+ \__kernel_msg_expandable_error:nn
+ { kernel } { misplaced-equals-sign }
+ }
% \end{macrocode}
% \end{macro}
% \end{macro}
%
-% \begin{macro}[EXP]{\@@_key:nN}
-% This will get the current key with spaces trimmed and \meta{function_1} as
-% its arguments. All it has to do is put them in an \cs{exp_not:n} and reorder
-% them.
+% \begin{macro}[EXP]{\@@_end_loop_other:w, \@@_end_loop_active:w}
+% All that's left for the parsing loops are the macros which end the
+% recursion. Both just gobble the remaining tokens of the respective loop
+% including the next recursion call.
% \begin{macrocode}
-\cs_new:Npn \@@_key:nN #1 #2
- { \exp_not:n { #2 { #1 } } }
+ \cs_new:Npn \@@_end_loop_other:w
+ \s_@@_tail
+ \@@_split_active:w ##1 \s_@@_nil
+ \s_@@_mark \@@_split_active_auxi:w
+ #2 \s_@@_mark \@@_clean_up_active:w
+ \s_@@_stop
+ ##2 ##3
+ \@@_loop_other:NNw ##4 \s_@@_mark
+ { }
+ \cs_new:Npn \@@_end_loop_active:w
+ \s_@@_tail
+ \@@_loop_other:NNw ##1 , \s_@@_tail ,
+ \@@_loop_active:NNw ##2 \s_@@_mark
+ { }
% \end{macrocode}
% \end{macro}
%
-% \begin{macro}[EXP]{\@@_key_val:nnN}
-% This will get the key name and value with spaces trimmed. It has to
-% assert that the key name isn't empty. Afterwards put them into an
-% \cs{exp_not:n} together with \meta{function_2}. If the key is empty they are
-% gobbled instead.
+% The parsing loops are done, so here ends the definition of \cs{@@_tmp:NN},
+% which will finally set up the macros.
% \begin{macrocode}
-\cs_new:Npn \@@_key_val:nnN #1 #2 #3
+ }
+ \char_set_catcode_active:n { `\, }
+ \char_set_catcode_active:n { `\= }
+ \@@_tmp:NN , =
+\group_end:
+% \end{macrocode}
+%
+% \begin{macro}[EXP]{\@@_pair:nnNN, \@@_key:nNN}
+% These macros will be called on the parsed keys and values of the key--value
+% list. All arguments are completely trimmed. They test for blank key names
+% and call the functions passed to \cs{keyval_parse:NNn} inside of
+% \cs{exp_not:n} with the correct arguments.
+% \begin{macrocode}
+\cs_new:Npn \@@_pair:nnNN #1 #2 #3 #4
+ {
+ \@@_if_blank:w \s_@@_mark #2 \s_@@_nil \s_@@_stop \@@_blank_key_error:w
+ \s_@@_mark \s_@@_stop
+ \exp_not:n { #4 { #2 } { #1 } }
+ }
+\cs_new:Npn \@@_key:nNN #1 #2 #3
{
- \@@_if_empty:w \s_@@_mark #2 \s_@@_stop
- \@@_empty_key:w \s_@@_mark \s_@@_stop
- \exp_not:n { #3 { #2 } { #1 } }
+ \@@_if_blank:w \s_@@_mark #1 \s_@@_nil \s_@@_stop \@@_blank_key_error:w
+ \s_@@_mark \s_@@_stop
+ \exp_not:n { #2 { #1 } }
}
% \end{macrocode}
% \end{macro}
@@ -1143,46 +1253,31 @@
% with an arbitrary token following the argument. Each of these utilize the
% fact that the argument will contain a leading \cs{s_@@_mark}.
% \begin{macrocode}
-\cs_new:Npn \@@_if_empty:w #1 \s_@@_mark \s_@@_stop {}
+\cs_new:Npn \@@_if_empty:w #1 \s_@@_mark \s_@@_stop { }
\cs_new:Npn \@@_if_blank:w \s_@@_mark #1 { \@@_if_empty:w \s_@@_mark }
-\cs_new:Npn \@@_if_recursion_tail:w #1 \s_@@_mark \s_@@_tail {}
+\cs_new:Npn \@@_if_recursion_tail:w \s_@@_mark #1 \s_@@_tail { }
% \end{macrocode}
% \end{macro}
%
-% \begin{macro}[EXP]{\@@_has_false:w,\@@_blank_true:w,\@@_empty_key:w}
+% \begin{macro}[EXP]{\@@_blank_true:w,\@@_blank_key_error:w}
% These macros will be called if the tests above didn't gobble them, they
% execute the branching.
% \begin{macrocode}
-\cs_new:Npn \@@_has_false:w \s_@@_mark \s_@@_stop \use_i:nn #1 #2 { #2 }
-\cs_new:Npn \@@_blank_true:w \s_@@_mark \s_@@_stop \use:n #1 {}
-\cs_new:Npn \@@_empty_key:w \s_@@_mark \s_@@_stop \exp_not:n #1
- { \@@_misplaced_equal_error: }
-% \end{macrocode}
-% \end{macro}
-%
-% \begin{macro}[EXP]{\@@_if_has_equal_other:w}
-% Another test that works by gobbling tokens until a specific one is hit.
-% \begin{macrocode}
-\cs_new:Npn \@@_if_has_equal_other:w #1 =
- { \@@_if_empty:w \s_@@_mark }
-% \end{macrocode}
-% \end{macro}
-%
-% \begin{macro}[EXP]{\@@_misplaced_equal_error:}
-% Just throw an error expandably. This is hid inside a macro so that other
-% macros don't have to gobble so many tokens, which increases speed for
-% correct input. This will marginally slow down the error case, but that
-% doesn't have to be fast anyway.
-% \begin{macrocode}
-\cs_new:Npn \@@_misplaced_equal_error:
- { \__kernel_msg_expandable_error:nn { kernel } { misplaced-equals-sign } }
+\cs_new:Npn \@@_blank_true:w \s_@@_mark \s_@@_stop \use:n #1 #2 #3 { }
+\cs_new:Npn \@@_blank_key_error:w \s_@@_mark \s_@@_stop \exp_not:n #1
+ {
+ \__kernel_msg_expandable_error:nn
+ { kernel } { blank-key-name }
+ }
% \end{macrocode}
% \end{macro}
%
-% One message for the low level parsing system.
+% Two messages for the low level parsing system.
% \begin{macrocode}
\__kernel_msg_new:nnn { kernel } { misplaced-equals-sign }
{ Misplaced~equals~sign~in~key-value~input~\msg_line_context: }
+\__kernel_msg_new:nnn { kernel } { blank-key-name }
+ { Blank~key~name~in~key-value~input~\msg_line_context: }
% \end{macrocode}
%
% \begin{macro}[EXP]{\@@_trim:nN}
@@ -1203,7 +1298,7 @@
\@@_trim_auxi:w
##1
\s_@@_nil
- \s_@@_mark #1 {}
+ \s_@@_mark #1 { }
\s_@@_mark \@@_trim_auxii:w
\@@_trim_auxiii:w
#1 \s_@@_nil
@@ -1482,11 +1577,11 @@
\cs_if_exist:cTF { \c_@@_props_root_str \l_@@_property_str }
{ \@@_define_code:n {#2} }
{
- \str_if_empty:NF \l_@@_property_str
- {
- \__kernel_msg_error:nnxx { kernel } { key-property-unknown }
- { \l_@@_property_str } { \l_keys_path_str }
- }
+ \str_if_empty:NF \l_@@_property_str
+ {
+ \__kernel_msg_error:nnxx { kernel } { key-property-unknown }
+ { \l_@@_property_str } { \l_keys_path_str }
+ }
}
}
% \end{macrocode}
@@ -2729,7 +2824,7 @@
}
{
\__kernel_msg_error:nnxx { kernel } { key-unknown }
- { \l_keys_path_str } { \l_@@_module_str }
+ { \l_keys_path_str } { \l_@@_module_str }
}
}
}
diff --git a/Master/texmf-dist/source/latex/l3kernel/l3legacy.dtx b/Master/texmf-dist/source/latex/l3kernel/l3legacy.dtx
index 1c017035de8..b491255503c 100644
--- a/Master/texmf-dist/source/latex/l3kernel/l3legacy.dtx
+++ b/Master/texmf-dist/source/latex/l3kernel/l3legacy.dtx
@@ -43,7 +43,7 @@
% }^^A
% }
%
-% \date{Released 2020-05-11}
+% \date{Released 2020-05-14}
%
% \maketitle
%
diff --git a/Master/texmf-dist/source/latex/l3kernel/l3luatex.dtx b/Master/texmf-dist/source/latex/l3kernel/l3luatex.dtx
index 5b3c8243fe0..fd8c5ed6e01 100644
--- a/Master/texmf-dist/source/latex/l3kernel/l3luatex.dtx
+++ b/Master/texmf-dist/source/latex/l3kernel/l3luatex.dtx
@@ -43,7 +43,7 @@
% }^^A
% }
%
-% \date{Released 2020-05-11}
+% \date{Released 2020-05-14}
%
% \maketitle
%
diff --git a/Master/texmf-dist/source/latex/l3kernel/l3msg.dtx b/Master/texmf-dist/source/latex/l3kernel/l3msg.dtx
index feb233bf54c..5547c3ddc79 100644
--- a/Master/texmf-dist/source/latex/l3kernel/l3msg.dtx
+++ b/Master/texmf-dist/source/latex/l3kernel/l3msg.dtx
@@ -43,7 +43,7 @@
% }^^A
% }
%
-% \date{Released 2020-05-11}
+% \date{Released 2020-05-14}
%
% \maketitle
%
diff --git a/Master/texmf-dist/source/latex/l3kernel/l3names.dtx b/Master/texmf-dist/source/latex/l3kernel/l3names.dtx
index 2878654f585..3f9a7309c96 100644
--- a/Master/texmf-dist/source/latex/l3kernel/l3names.dtx
+++ b/Master/texmf-dist/source/latex/l3kernel/l3names.dtx
@@ -43,7 +43,7 @@
% }^^A
% }
%
-% \date{Released 2020-05-11}
+% \date{Released 2020-05-14}
%
% \maketitle
%
diff --git a/Master/texmf-dist/source/latex/l3kernel/l3prg.dtx b/Master/texmf-dist/source/latex/l3kernel/l3prg.dtx
index d14576f08c0..34a14829c7d 100644
--- a/Master/texmf-dist/source/latex/l3kernel/l3prg.dtx
+++ b/Master/texmf-dist/source/latex/l3kernel/l3prg.dtx
@@ -43,7 +43,7 @@
% }^^A
% }
%
-% \date{Released 2020-05-11}
+% \date{Released 2020-05-14}
%
% \maketitle
%
diff --git a/Master/texmf-dist/source/latex/l3kernel/l3prop.dtx b/Master/texmf-dist/source/latex/l3kernel/l3prop.dtx
index c586164260d..33741fecf0a 100644
--- a/Master/texmf-dist/source/latex/l3kernel/l3prop.dtx
+++ b/Master/texmf-dist/source/latex/l3kernel/l3prop.dtx
@@ -43,7 +43,7 @@
% }^^A
% }
%
-% \date{Released 2020-05-11}
+% \date{Released 2020-05-14}
%
% \maketitle
%
diff --git a/Master/texmf-dist/source/latex/l3kernel/l3quark.dtx b/Master/texmf-dist/source/latex/l3kernel/l3quark.dtx
index f513fcb026a..9068f7bbecd 100644
--- a/Master/texmf-dist/source/latex/l3kernel/l3quark.dtx
+++ b/Master/texmf-dist/source/latex/l3kernel/l3quark.dtx
@@ -43,7 +43,7 @@
% }^^A
% }
%
-% \date{Released 2020-05-11}
+% \date{Released 2020-05-14}
%
% \maketitle
%
diff --git a/Master/texmf-dist/source/latex/l3kernel/l3regex.dtx b/Master/texmf-dist/source/latex/l3kernel/l3regex.dtx
index 7c2d8e7504a..80e2ffa8960 100644
--- a/Master/texmf-dist/source/latex/l3kernel/l3regex.dtx
+++ b/Master/texmf-dist/source/latex/l3kernel/l3regex.dtx
@@ -43,7 +43,7 @@
% }^^A
% }
%
-% \date{Released 2020-05-11}
+% \date{Released 2020-05-14}
%
% \maketitle
%
diff --git a/Master/texmf-dist/source/latex/l3kernel/l3seq.dtx b/Master/texmf-dist/source/latex/l3kernel/l3seq.dtx
index 56c4bc1fda7..830adba2cb3 100644
--- a/Master/texmf-dist/source/latex/l3kernel/l3seq.dtx
+++ b/Master/texmf-dist/source/latex/l3kernel/l3seq.dtx
@@ -43,7 +43,7 @@
% }^^A
% }
%
-% \date{Released 2020-05-11}
+% \date{Released 2020-05-14}
%
% \maketitle
%
diff --git a/Master/texmf-dist/source/latex/l3kernel/l3skip.dtx b/Master/texmf-dist/source/latex/l3kernel/l3skip.dtx
index 8cfd78d6f14..a4973652c1f 100644
--- a/Master/texmf-dist/source/latex/l3kernel/l3skip.dtx
+++ b/Master/texmf-dist/source/latex/l3kernel/l3skip.dtx
@@ -44,7 +44,7 @@
% }^^A
% }
%
-% \date{Released 2020-05-11}
+% \date{Released 2020-05-14}
%
% \maketitle
%
diff --git a/Master/texmf-dist/source/latex/l3kernel/l3sort.dtx b/Master/texmf-dist/source/latex/l3kernel/l3sort.dtx
index 6b41acfe3ee..89c085f7782 100644
--- a/Master/texmf-dist/source/latex/l3kernel/l3sort.dtx
+++ b/Master/texmf-dist/source/latex/l3kernel/l3sort.dtx
@@ -43,7 +43,7 @@
% }^^A
% }
%
-% \date{Released 2020-05-11}
+% \date{Released 2020-05-14}
%
% \maketitle
%
diff --git a/Master/texmf-dist/source/latex/l3kernel/l3str-convert.dtx b/Master/texmf-dist/source/latex/l3kernel/l3str-convert.dtx
index 4620342091a..88bf391f25b 100644
--- a/Master/texmf-dist/source/latex/l3kernel/l3str-convert.dtx
+++ b/Master/texmf-dist/source/latex/l3kernel/l3str-convert.dtx
@@ -44,7 +44,7 @@
% }^^A
% }
%
-% \date{Released 2020-05-11}
+% \date{Released 2020-05-14}
%
% \maketitle
%
diff --git a/Master/texmf-dist/source/latex/l3kernel/l3str.dtx b/Master/texmf-dist/source/latex/l3kernel/l3str.dtx
index d4cbc2bb49f..d15ee54ed18 100644
--- a/Master/texmf-dist/source/latex/l3kernel/l3str.dtx
+++ b/Master/texmf-dist/source/latex/l3kernel/l3str.dtx
@@ -43,7 +43,7 @@
% }^^A
% }
%
-% \date{Released 2020-05-11}
+% \date{Released 2020-05-14}
%
% \maketitle
%
diff --git a/Master/texmf-dist/source/latex/l3kernel/l3sys.dtx b/Master/texmf-dist/source/latex/l3kernel/l3sys.dtx
index feef7117355..fe96f7aec5b 100644
--- a/Master/texmf-dist/source/latex/l3kernel/l3sys.dtx
+++ b/Master/texmf-dist/source/latex/l3kernel/l3sys.dtx
@@ -43,7 +43,7 @@
% }^^A
% }
%
-% \date{Released 2020-05-11}
+% \date{Released 2020-05-14}
%
% \maketitle
%
diff --git a/Master/texmf-dist/source/latex/l3kernel/l3text-case.dtx b/Master/texmf-dist/source/latex/l3kernel/l3text-case.dtx
index ad71e493198..51819ed5145 100644
--- a/Master/texmf-dist/source/latex/l3kernel/l3text-case.dtx
+++ b/Master/texmf-dist/source/latex/l3kernel/l3text-case.dtx
@@ -43,7 +43,7 @@
% }^^A
% }
%
-% \date{Released 2020-05-11}
+% \date{Released 2020-05-14}
%
% \maketitle
%
diff --git a/Master/texmf-dist/source/latex/l3kernel/l3text-purify.dtx b/Master/texmf-dist/source/latex/l3kernel/l3text-purify.dtx
index 070e41956fb..54266ba72c8 100644
--- a/Master/texmf-dist/source/latex/l3kernel/l3text-purify.dtx
+++ b/Master/texmf-dist/source/latex/l3kernel/l3text-purify.dtx
@@ -43,7 +43,7 @@
% }^^A
% }
%
-% \date{Released 2020-05-11}
+% \date{Released 2020-05-14}
%
% \maketitle
%
diff --git a/Master/texmf-dist/source/latex/l3kernel/l3text.dtx b/Master/texmf-dist/source/latex/l3kernel/l3text.dtx
index 5113e03cc9c..0f8f24cafd3 100644
--- a/Master/texmf-dist/source/latex/l3kernel/l3text.dtx
+++ b/Master/texmf-dist/source/latex/l3kernel/l3text.dtx
@@ -43,7 +43,7 @@
% }^^A
% }
%
-% \date{Released 2020-05-11}
+% \date{Released 2020-05-14}
%
% \maketitle
%
diff --git a/Master/texmf-dist/source/latex/l3kernel/l3tl-analysis.dtx b/Master/texmf-dist/source/latex/l3kernel/l3tl-analysis.dtx
index 6fbe2f1bbb8..2a6b31f537a 100644
--- a/Master/texmf-dist/source/latex/l3kernel/l3tl-analysis.dtx
+++ b/Master/texmf-dist/source/latex/l3kernel/l3tl-analysis.dtx
@@ -44,7 +44,7 @@
% }^^A
% }
%
-% \date{Released 2020-05-11}
+% \date{Released 2020-05-14}
%
% \maketitle
%
diff --git a/Master/texmf-dist/source/latex/l3kernel/l3tl.dtx b/Master/texmf-dist/source/latex/l3kernel/l3tl.dtx
index 53f61e97508..b3d6c3ddaca 100644
--- a/Master/texmf-dist/source/latex/l3kernel/l3tl.dtx
+++ b/Master/texmf-dist/source/latex/l3kernel/l3tl.dtx
@@ -43,7 +43,7 @@
% }^^A
% }
%
-% \date{Released 2020-05-11}
+% \date{Released 2020-05-14}
%
% \maketitle
%
diff --git a/Master/texmf-dist/source/latex/l3kernel/l3token.dtx b/Master/texmf-dist/source/latex/l3kernel/l3token.dtx
index 0608820bbac..0ed1350b035 100644
--- a/Master/texmf-dist/source/latex/l3kernel/l3token.dtx
+++ b/Master/texmf-dist/source/latex/l3kernel/l3token.dtx
@@ -43,7 +43,7 @@
% }^^A
% }
%
-% \date{Released 2020-05-11}
+% \date{Released 2020-05-14}
%
% \maketitle
%
diff --git a/Master/texmf-dist/source/latex/l3kernel/l3unicode.dtx b/Master/texmf-dist/source/latex/l3kernel/l3unicode.dtx
index bc0466eecae..6f2d533f584 100644
--- a/Master/texmf-dist/source/latex/l3kernel/l3unicode.dtx
+++ b/Master/texmf-dist/source/latex/l3kernel/l3unicode.dtx
@@ -43,7 +43,7 @@
% }^^A
% }
%
-% \date{Released 2020-05-11}
+% \date{Released 2020-05-14}
%
% \maketitle
%
diff --git a/Master/texmf-dist/source/latex/l3packages/l3keys2e/l3keys2e.dtx b/Master/texmf-dist/source/latex/l3packages/l3keys2e/l3keys2e.dtx
index d6701c4519a..6a09bb18bd7 100644
--- a/Master/texmf-dist/source/latex/l3packages/l3keys2e/l3keys2e.dtx
+++ b/Master/texmf-dist/source/latex/l3packages/l3keys2e/l3keys2e.dtx
@@ -62,7 +62,7 @@
% }^^A
% }
%
-% \date{Released 2020-03-06}
+% \date{Released 2020-05-14}
%
% \maketitle
%
@@ -139,7 +139,7 @@
% \end{macrocode}
%
% \begin{macrocode}
-\ProvidesExplPackage{l3keys2e}{2020-03-06}{}
+\ProvidesExplPackage{l3keys2e}{2020-05-14}{}
{LaTeX2e option processing using LaTeX3 keys}
% \end{macrocode}
%
@@ -299,8 +299,8 @@
% so that there will always be a sign available.
% \begin{macrocode}
\cs_new:Npn \@@_latexe_remove_equals:n #1
- { \@@_latexe_remove_equals:w #1 = \q_stop }
-\cs_new:Npn \@@_latexe_remove_equals:w #1 = #2 \q_stop { \exp_not:n {#1} }
+ { \@@_latexe_remove_equals:w #1 = \s_@@_stop }
+\cs_new:Npn \@@_latexe_remove_equals:w #1 = #2 \s_@@_stop { \exp_not:n {#1} }
% \end{macrocode}
% \end{macro}
% \end{macro}
diff --git a/Master/texmf-dist/source/latex/l3packages/xfp/xfp.dtx b/Master/texmf-dist/source/latex/l3packages/xfp/xfp.dtx
index afdd9e189cd..e0ebede0f90 100644
--- a/Master/texmf-dist/source/latex/l3packages/xfp/xfp.dtx
+++ b/Master/texmf-dist/source/latex/l3packages/xfp/xfp.dtx
@@ -64,7 +64,7 @@
% }^^A
% }
%
-% \date{Released 2020-03-06}
+% \date{Released 2020-05-14}
%
% \maketitle
%
@@ -167,7 +167,7 @@
% \end{macrocode}
%
% \begin{macrocode}
-\ProvidesExplPackage{xfp}{2020-03-06}{}
+\ProvidesExplPackage{xfp}{2020-05-14}{}
{L3 Floating point unit}
% \end{macrocode}
%
diff --git a/Master/texmf-dist/source/latex/l3packages/xfrac/xfrac.dtx b/Master/texmf-dist/source/latex/l3packages/xfrac/xfrac.dtx
index 7be07c978e6..275aa6859a8 100644
--- a/Master/texmf-dist/source/latex/l3packages/xfrac/xfrac.dtx
+++ b/Master/texmf-dist/source/latex/l3packages/xfrac/xfrac.dtx
@@ -65,7 +65,7 @@
% }^^A
% }
%
-% \date{Released 2020-03-06}
+% \date{Released 2020-05-14}
%
% \maketitle
%
@@ -535,7 +535,7 @@
% \end{macrocode}
%
% \begin{macrocode}
-\ProvidesExplPackage{xfrac}{2020-03-06}{}
+\ProvidesExplPackage{xfrac}{2020-05-14}{}
{L3 Experimental split-level fractions}
% \end{macrocode}
%
diff --git a/Master/texmf-dist/source/latex/l3packages/xparse/xparse.dtx b/Master/texmf-dist/source/latex/l3packages/xparse/xparse.dtx
index f56bcdf5e97..c7004349030 100644
--- a/Master/texmf-dist/source/latex/l3packages/xparse/xparse.dtx
+++ b/Master/texmf-dist/source/latex/l3packages/xparse/xparse.dtx
@@ -67,7 +67,7 @@
% }^^A
% }
%
-% \date{Released 2020-03-06}
+% \date{Released 2020-05-14}
%
% \maketitle
%
@@ -304,7 +304,7 @@
% follow such a command. The most common example is the use of \cmd{\\} in
% \pkg{amsmath} environments. In \pkg{xparse} terms it has signature
% \begin{verbatim}
-% \DeclareDocumentCommad \\ { !s !o } { ... }
+% \DeclareDocumentCommand \\ { !s !o } { ... }
% \end{verbatim}
%
% \subsection{Required delimited arguments}
@@ -993,7 +993,7 @@
% \end{macrocode}
%
% \begin{macrocode}
-\ProvidesExplPackage{xparse}{2020-03-06}{}
+\ProvidesExplPackage{xparse}{2020-05-14}{}
{L3 Experimental document command parser}
% \end{macrocode}
%
@@ -1019,22 +1019,31 @@
% \end{variable}
% \end{variable}
%
+% \begin{macrocode}
+%</package>
+% \end{macrocode}
+%
% \subsection{Reload check}
%
% A simple reload check.
% \begin{macrocode}
+%<*core>
\cs_if_exist:NT \NewDocumentCommand
{ \file_input_stop: }
+%</core>
% \end{macrocode}
%
+% Load the core code.
% \begin{macrocode}
-%</package>
+%<*2ekernel|package>
+\file_input:n { xparse-generic.tex }
+%</2ekernel|package>
% \end{macrocode}
%
% \subsection{Variables and constants}
%
% \begin{macrocode}
-%<*package|2ekernel>
+%<*!package>
% \end{macrocode}
%
% \begin{variable}{\c_@@_special_chars_seq}
@@ -1049,6 +1058,17 @@
% \end{macrocode}
% \end{variable}
%
+% \begin{macrocode}
+%<*core>
+\if_charcode:w xx
+ \cs_new:Npn \@@_file_end_hook: { }
+\else
+ \ExplSyntaxOn
+ \cs_new:Npn \@@_file_end_hook: { \ExplSyntaxOff }
+\fi:
+%</core>
+% \end{macrocode}
+%
% \begin{variable}{\l_@@_arg_spec_tl}
% Holds the argument specification after normalization of shorthands.
% \begin{macrocode}
@@ -1477,9 +1497,9 @@
%<*initex>
\cs_if_exist:cTF { environment~ \l_@@_environment_str }
%</initex>
-%<*package|2ekernel>
+%<*core>
\cs_if_exist:cTF { \l_@@_environment_str }
-%</package|2ekernel>
+%</core>
{
\__kernel_msg_info:nnxx { xparse } { redefine-environment }
{ \l_@@_environment_str } { \tl_to_str:n {#2} }
@@ -1525,10 +1545,10 @@
\cs_generate_from_arg_count:cNnn
{ environment~ #1 ~end~aux~ } \cs_set:Npn
\l_@@_current_arg_int {#4}
-%<*package|2ekernel>
+%<*core>
\cs_set_eq:cc {#1} { environment~ #1 }
\cs_set_eq:cc { end #1 } { environment~ #1 ~end }
-%</package|2ekernel>
+%</core>
}
}
% \end{macrocode}
@@ -1548,9 +1568,9 @@
% \begin{macrocode}
\cs_new_protected:Npn \@@_start_env:nnnnn #1#2
{
-%<*package|2ekernel>
+%<*core>
\cs_if_exist_use:N \conditionally@traceoff
-%</package|2ekernel>
+%</core>
\str_set:Nn \l_@@_environment_str {#2}
\bool_set_true:N \l_@@_environment_bool
\@@_start_aux:ccnnnn
@@ -1560,9 +1580,9 @@
}
\cs_new_protected:Npx \@@_start:nNNnnn #1#2#3
{
-%<*package|2ekernel>
+%<*core>
\exp_not:n { \cs_if_exist_use:N \conditionally@traceoff }
-%</package|2ekernel>
+%</core>
\exp_not:c { xparse~function~is~not~expandable }
\exp_not:n { \bool_set_false:N \l_@@_environment_bool }
\exp_not:N \@@_start_aux:NNnnnn
@@ -1599,9 +1619,9 @@
{
\tl_if_empty:NF \l_@@_defaults_tl { \@@_defaults: }
\tl_if_empty:NF \l_@@_process_all_tl { \@@_args_process: }
-%<*package|2ekernel>
+%<*core>
\cs_if_exist_use:N \conditionally@traceon
-%</package|2ekernel>
+%</core>
\exp_after:wN \l_@@_fn_code_tl \l_@@_args_tl
}
% \end{macrocode}
@@ -1885,11 +1905,39 @@
\int_incr:N \l_@@_current_arg_int
\cs_if_exist_use:cF { @@_normalize_type_ \tl_to_str:n {#1} :w }
{
+ \bool_lazy_any:nTF
+ {
+ { \str_if_eq_p:nn {#1} { G } }
+ { \str_if_eq_p:nn {#1} { g } }
+ { \str_if_eq_p:nn {#1} { l } }
+ { \str_if_eq_p:nn {#1} { u } }
+ }
+ {
+ \__kernel_msg_error:nnxx { xparse } { xparse-argument-type }
+ { \@@_environment_or_command: } { \tl_to_str:n {#1} }
+ }
+ {
+ \__kernel_msg_error:nnxx { xparse } { unknown-argument-type }
+ { \@@_environment_or_command: } { \tl_to_str:n {#1} }
+ }
+ \@@_bad_def:wn
+ }
+ }
+%</!package>
+%<*package>
+\cs_gset_protected:Npn \@@_normalize_arg_spec_loop:n #1
+ {
+ \quark_if_recursion_tail_stop:n {#1}
+ \int_incr:N \l_@@_current_arg_int
+ \cs_if_exist_use:cF { @@_normalize_type_ \tl_to_str:n {#1} :w }
+ {
\__kernel_msg_error:nnxx { xparse } { unknown-argument-type }
{ \@@_environment_or_command: } { \tl_to_str:n {#1} }
\@@_bad_def:wn
}
}
+%</package>
+%<*!package>
% \end{macrocode}
% \end{macro}
% \end{macro}
@@ -1923,8 +1971,6 @@
\quark_if_recursion_tail_stop_do:nn {##1} { \@@_bad_arg_spec:wn }
\@@_normalize_type_E:w {##1} { }
}
- \cs_new_protected:Npn \@@_normalize_type_g:w
- { \@@_normalize_type_G:w {#1} }
\cs_new_protected:Npn \@@_normalize_type_o:w
{ \@@_normalize_type_D:w [ ] {#1} }
\cs_new_protected:Npn \@@_normalize_type_O:w
@@ -1938,6 +1984,12 @@
{ \@@_normalize_type_t:w * }
}
\exp_args:No \@@_tmp:w { \c_novalue_tl }
+%</!package>
+%<*package>
+\cs_new_protected:Npx \@@_normalize_type_g:w
+ { \exp_not:N \@@_normalize_type_G:w { \exp_not:V \c_novalue_tl } }
+%</package>
+%<*!package>
% \end{macrocode}
% \end{macro}
%
@@ -2051,6 +2103,8 @@
\@@_normalize_E_unique_check:w #2 \q_stop
}
}
+%</!package>
+%<*package>
\cs_new_protected:Npn \@@_normalize_type_G:w #1
{
\quark_if_recursion_tail_stop_do:nn {#1} { \@@_bad_arg_spec:wn }
@@ -2059,6 +2113,8 @@
\tl_put_right:Nn \l_@@_last_delimiters_tl { { } }
\@@_normalize_arg_spec_loop:n
}
+%</package>
+%<*!package>
\cs_new_protected:Npn \@@_normalize_type_t:w #1
{
\quark_if_recursion_tail_stop_do:Nn #1 { \@@_bad_arg_spec:wn }
@@ -2095,12 +2151,16 @@
% \cs{l_@@_arg_spec_tl}, count the mandatory argument, and empty the
% list of last delimiters.
% \begin{macrocode}
+%</!package>
+%<*package>
\cs_new_protected:Npn \@@_normalize_type_l:w
{
\@@_normalize_check_lu:N l
\@@_add_arg_spec_mandatory:n { l }
\@@_normalize_arg_spec_loop:n
}
+%</package>
+%<*!package>
\cs_new_protected:Npn \@@_normalize_type_m:w
{
\@@_delimiter_check:nnn { } { m } { \iow_char:N \{ }
@@ -2117,6 +2177,8 @@
\@@_add_arg_spec_mandatory:n { R #1 #2 {#3} }
\@@_normalize_arg_spec_loop:n
}
+%</!package>
+%<*package>
\cs_new_protected:Npn \@@_normalize_type_u:w #1
{
\quark_if_recursion_tail_stop_do:nn {#1} { \@@_bad_arg_spec:wn }
@@ -2124,6 +2186,8 @@
\@@_add_arg_spec_mandatory:n { u {#1} }
\@@_normalize_arg_spec_loop:n
}
+%</package>
+%<*!package>
\cs_new_protected:Npn \@@_normalize_type_v:w
{
\@@_normalize_check_gv:N v
@@ -2482,6 +2546,8 @@
% For the \texttt{G} type, the grabber and the default are added to the
% signature.
% \begin{macrocode}
+%</!package>
+%<*package>
\cs_new_protected:Npn \@@_add_type_G:w #1
{
\@@_flush_m_args:
@@ -2503,6 +2569,8 @@
\@@_add_grabber:N l
\@@_prepare_signature:N
}
+%</package>
+%<*!package>
% \end{macrocode}
% \end{macro}
%
@@ -2558,6 +2626,8 @@
% At the set up stage, the \texttt{u} type argument is identical to the
% \texttt{G} type except for the name of the grabber function.
% \begin{macrocode}
+%</!package>
+%<*package>
\cs_new_protected:Npn \@@_add_type_u:w #1
{
\@@_flush_m_args:
@@ -2566,6 +2636,8 @@
\tl_put_right:Nn \l_@@_signature_tl { {#1} }
\@@_prepare_signature:N
}
+%</package>
+%<*!package>
% \end{macrocode}
% \end{macro}
%
@@ -2784,8 +2856,12 @@
% parameter text ends with |#| in fact end up being delimited by an
% open brace.
% \begin{macrocode}
+%</!package>
+%<*package>
\cs_new_protected:Npn \@@_add_expandable_type_l:w
{ \@@_add_expandable_type_u:w ## }
+%</package>
+%<*!package>
% \end{macrocode}
% \end{macro}
%
@@ -2834,6 +2910,8 @@
% Define an auxiliary that will be used directly in the signature. It
% grabs one argument delimited by |#1| and places it before \cs{q_@@}.
% \begin{macrocode}
+%</!package>
+%<*package>
\cs_new_protected:Npn \@@_add_expandable_type_u:w #1
{
\@@_add_default:
@@ -2846,6 +2924,8 @@
{ \exp_not:c { \l_@@_expandable_aux_name_tl } }
\@@_prepare_signature:N
}
+%</package>
+%<*!package>
% \end{macrocode}
% \end{macro}
%
@@ -3249,6 +3329,8 @@
% Optional groups are checked by meaning, so that the same code will
% work with, for example, \ConTeXt{}-like input.
% \begin{macrocode}
+%</!package>
+%<*package>
\cs_new_protected:Npn \@@_grab_G:w #1 \@@_run_code:
{
\@@_grab_G_aux:nNN {#1} \cs_set_protected_nopar:Npn
@@ -3278,6 +3360,8 @@
{ \l_@@_fn_tl }
{ \@@_add_arg:o \c_novalue_tl }
}
+%</package>
+%<*!package>
% \end{macrocode}
% \end{macro}
% \end{macro}
@@ -3290,6 +3374,8 @@
% \begin{macro}{\@@_grab_l_aux:nN}
% Argument grabbers for mandatory \TeX{} arguments are pretty simple.
% \begin{macrocode}
+%</!package>
+%<*package>
\cs_new_protected:Npn \@@_grab_l:w #1 \@@_run_code:
{ \@@_grab_l_aux:nN {#1} \cs_set_protected_nopar:Npn }
\cs_new_protected:Npn \@@_grab_l_long:w #1 \@@_run_code:
@@ -3301,6 +3387,8 @@
{ \@@_add_arg:n {##1} }
\l_@@_fn_tl
}
+%</package>
+%<*!package>
% \end{macrocode}
% \end{macro}
% \end{macro}
@@ -3472,6 +3560,8 @@
% Grabbing up to a list of tokens is quite easy: define the grabber,
% and then collect.
% \begin{macrocode}
+%</!package>
+%<*package>
\cs_new_protected:Npn \@@_grab_u:w #1#2 \@@_run_code:
{ \@@_grab_u_aux:nnN {#1} {#2} \cs_set_protected_nopar:Npn }
\cs_new_protected:Npn \@@_grab_u_long:w #1#2 \@@_run_code:
@@ -3483,6 +3573,8 @@
{ \@@_add_arg:n {##1} }
\l_@@_fn_tl
}
+%</package>
+%<*!package>
% \end{macrocode}
% \end{macro}
% \end{macro}
@@ -3694,10 +3786,10 @@
\c_@@_special_chars_seq
\char_set_catcode_other:N
%</initex>
-%<*package|2ekernel>
+%<*core>
\cs_set_eq:NN \do \char_set_catcode_other:N
\dospecials
-%</package|2ekernel>
+%</core>
\tex_endlinechar:D = `\^^M \scan_stop:
\bool_if:NTF \l_@@_long_bool
{ \char_set_catcode_other:n { \tex_endlinechar:D } }
@@ -4762,6 +4854,13 @@
The~letter~'#2'~does~not~specify~a~known~argument~type.
\c_@@_ignore_def_tl
}
+\__kernel_msg_new:nnnn { xparse } { xparse-argument-type }
+ { Deprecated~argument~type~'#2'~for~the~#1~requires~xparse. }
+ {
+ The~letter~'#2'~specifies~a~known~argument~type~that~requires~
+ the~xparse~package.
+ \c_@@_ignore_def_tl
+ }
% \end{macrocode}
%
% Errors when using commands/environments. The \texttt{if-boolean}
@@ -5112,18 +5211,15 @@
%
% \begin{macrocode}
%<*2ekernel>
-% \end{macrocode}
-%
-% \begin{macrocode}
\ExplSyntaxOff
-% \end{macrocode}
-%
-% \begin{macrocode}
%</2ekernel>
% \end{macrocode}
%
% \begin{macrocode}
-%</package|2ekernel>
+%<*core>
+\@@_file_end_hook:
+%</core>
+%</!package>
% \end{macrocode}
%
% \end{implementation}
diff --git a/Master/texmf-dist/source/latex/l3packages/xparse/xparse.ins b/Master/texmf-dist/source/latex/l3packages/xparse/xparse.ins
index d40f7cd6f2a..17a94782a46 100644
--- a/Master/texmf-dist/source/latex/l3packages/xparse/xparse.ins
+++ b/Master/texmf-dist/source/latex/l3packages/xparse/xparse.ins
@@ -42,7 +42,8 @@ and all files in that bundle must be distributed together.
\keepsilent
-\generate{\file{xparse.sty} {\from{xparse.dtx} {package}}
- \file{xparse.ltx} {\from{xparse.dtx} {2ekernel}}}
+\generate{\file{xparse-generic.tex}{\from{xparse.dtx}{core}}
+ \file{xparse.sty}{\from{xparse.dtx}{package}}
+ \file{xparse.ltx}{\from{xparse.dtx}{2ekernel}}}
\endbatchfile
diff --git a/Master/texmf-dist/source/latex/l3packages/xtemplate/xtemplate.dtx b/Master/texmf-dist/source/latex/l3packages/xtemplate/xtemplate.dtx
index 2236b30f979..897d1d3f844 100644
--- a/Master/texmf-dist/source/latex/l3packages/xtemplate/xtemplate.dtx
+++ b/Master/texmf-dist/source/latex/l3packages/xtemplate/xtemplate.dtx
@@ -63,7 +63,7 @@
% }^^A
% }
%
-% \date{Released 2020-03-06}
+% \date{Released 2020-05-14}
%
% \maketitle
%
@@ -682,7 +682,7 @@
% \end{macrocode}
%
% \begin{macrocode}
-\ProvidesExplPackage{xtemplate}{2020-03-06}{}
+\ProvidesExplPackage{xtemplate}{2020-05-14}{}
{L3 Experimental prototype document functions}
% \end{macrocode}
%
@@ -858,6 +858,28 @@
% \end{macrocode}
% \end{variable}
%
+% \begin{variable}{\s_@@_mark,\s_@@_stop}
+% Internal scan marks.
+% \begin{macrocode}
+\scan_new:N \s_@@_mark
+\scan_new:N \s_@@_stop
+% \end{macrocode}
+% \end{variable}
+%
+% \begin{variable}{\q_@@_nil}
+% Internal quarks.
+% \begin{macrocode}
+\quark_new:N \q_@@_nil
+% \end{macrocode}
+% \end{variable}
+%
+% \begin{macro}[pTF]{\@@_quark_if_nil:n}
+% Branching quark conditional.
+% \begin{macrocode}
+\__kernel_quark_new_conditional:Nn \@@_quark_if_nil:N { F }
+% \end{macrocode}
+% \end{macro}
+%
% \subsection{Variant of prop functions}
%
% \begin{macro}[TF]{\prop_get:NoN}
@@ -1300,7 +1322,7 @@
{
\tl_clear:N \l_@@_key_name_tl
\exp_after:wN \@@_split_keytype_aux:w
- \l_@@_tmp_tl \q_stop
+ \l_@@_tmp_tl \s_@@_stop
}
}
{
@@ -1311,7 +1333,7 @@
\use:x
{
\cs_new_protected:Npn \exp_not:N \@@_split_keytype_aux:w
- ##1 \token_to_str:N : ##2 \exp_not:N \q_stop
+ ##1 \token_to_str:N : ##2 \s_@@_stop
{
\tl_put_right:Nx \exp_not:N \l_@@_key_name_tl
{ \exp_not:N \tl_to_str:n {##1} }
@@ -1319,7 +1341,7 @@
{
\tl_put_right:Nn \exp_not:N \l_@@_key_name_tl
{ \token_to_str:N : }
- \exp_not:N \@@_split_keytype_aux:w ##2 \exp_not:N \q_stop
+ \exp_not:N \@@_split_keytype_aux:w ##2 \s_@@_stop
}
{
\exp_not:N \tl_if_empty:NTF \exp_not:N \l_@@_key_name_tl
@@ -1357,7 +1379,7 @@
\tl_if_in:nnT {#1} {##1}
{
\cs_set:Npn \@@_split_keytype_arg_aux:w
- ####1 ##1 ####2 \q_stop
+ ####1 ##1 ####2 \s_@@_stop
{
\tl_if_empty:nT {####1}
{
@@ -1366,7 +1388,7 @@
\seq_map_break:
}
}
- \@@_split_keytype_arg_aux:w #1 \q_stop
+ \@@_split_keytype_arg_aux:w #1 \s_@@_stop
}
}
\seq_map_function:NN \c_@@_keytypes_arg_seq
@@ -1374,7 +1396,7 @@
}
\cs_generate_variant:Nn \@@_split_keytype_arg:n { o }
\cs_new:Npn \@@_split_keytype_arg_aux:n #1 { }
-\cs_new:Npn \@@_split_keytype_arg_aux:w #1 \q_stop { }
+\cs_new:Npn \@@_split_keytype_arg_aux:w #1 \s_@@_stop { }
% \end{macrocode}
% \end{macro}
% \end{macro}
@@ -1628,7 +1650,7 @@
}
{
\tl_if_in:nnTF {#1} { global }
- { \@@_parse_vars_elt_aux:w #1 \q_stop }
+ { \@@_parse_vars_elt_aux:w #1 \s_@@_stop }
{
\msg_error:nnx { xtemplate } { bad-variable }
{ \tl_to_str:n {#1} }
@@ -1637,7 +1659,7 @@
}
}
}
-\cs_new_protected:Npn \@@_parse_vars_elt_aux:w #1 global #2 \q_stop
+\cs_new_protected:Npn \@@_parse_vars_elt_aux:w #1 global #2 \s_@@_stop
{
\tl_if_empty:nTF {#1}
{
@@ -2060,10 +2082,10 @@
\bool_set_false:N \l_@@_global_bool
\tl_if_in:onT \l_@@_var_tl { global }
{
- \exp_after:wN \@@_find_global_aux:w \l_@@_var_tl \q_stop
+ \exp_after:wN \@@_find_global_aux:w \l_@@_var_tl \s_@@_stop
}
}
-\cs_new_protected:Npn \@@_find_global_aux:w #1 global #2 \q_stop
+\cs_new_protected:Npn \@@_find_global_aux:w #1 global #2 \s_@@_stop
{
\tl_set:Nn \l_@@_var_tl {#2}
\bool_set_true:N \l_@@_global_bool
@@ -2377,16 +2399,16 @@
\l_@@_value_tl
{
\exp_after:wN \@@_key_to_value_auxii:w \l_@@_value_tl
- \q_mark global \q_nil \q_stop
+ \s_@@_mark global \q_@@_nil \s_@@_stop
}
{
\msg_error:nnx { xtemplate } { unknown-attribute }
{ \l_@@_tmp_tl }
}
}
-\cs_new_protected:Npn \@@_key_to_value_auxii:w #1 global #2#3 \q_stop
+\cs_new_protected:Npn \@@_key_to_value_auxii:w #1 global #2#3 \s_@@_stop
{
- \quark_if_nil:NF #2
+ \@@_quark_if_nil:NF #2
{ \tl_set:Nn \l_@@_value_tl {#2} }
}
% \end{macrocode}
diff --git a/Master/texmf-dist/tex/latex/l3kernel/expl3-code.tex b/Master/texmf-dist/tex/latex/l3kernel/expl3-code.tex
index 4e1b9a8bdc0..d68df11175c 100644
--- a/Master/texmf-dist/tex/latex/l3kernel/expl3-code.tex
+++ b/Master/texmf-dist/tex/latex/l3kernel/expl3-code.tex
@@ -68,7 +68,7 @@
%% and all files in that bundle must be distributed together.
%%
%% File: expl3.dtx
-\def\ExplFileDate{2020-05-11}%
+\def\ExplFileDate{2020-05-14}%
\begingroup
\def\next{\endgroup}%
\expandafter\ifx\csname PackageError\endcsname\relax
@@ -12818,92 +12818,144 @@
\cs_new:Npn \__keyval_loop_active:NNw ##1 ##2 ##3 #1
{
\__keyval_if_recursion_tail:w ##3
- \__keyval_end_loop_active:w \s__keyval_mark \s__keyval_tail
+ \__keyval_end_loop_active:w \s__keyval_tail
\__keyval_loop_other:NNw ##1 ##2 ##3 , \s__keyval_tail ,
\__keyval_loop_active:NNw ##1 ##2 \s__keyval_mark
}
+ \cs_new:Npn \__keyval_split_other:w ##1 = ##2 \s__keyval_mark ##3 ##4 \s__keyval_stop
+ { ##3 ##1 \s__keyval_stop \s__keyval_mark ##2 }
+ \cs_new:Npn \__keyval_split_active:w ##1 #2 ##2 \s__keyval_mark ##3 ##4 \s__keyval_stop
+ { ##3 ##1 \s__keyval_stop \s__keyval_mark ##2 }
\cs_new:Npn \__keyval_loop_other:NNw ##1 ##2 ##3 ,
{
\__keyval_if_recursion_tail:w ##3
- \__keyval_end_loop_other:w \s__keyval_mark \s__keyval_tail
- \__keyval_if_has_equal_other:w ##3 = \s__keyval_stop
- \__keyval_has_false:w \s__keyval_mark \s__keyval_stop \use_i:nn
- {
- \__keyval_if_has_equal_active:w ##3 #2 \s__keyval_stop
- \__keyval_has_false:w \s__keyval_mark \s__keyval_stop \use_i:nn
- \__keyval_misplaced_equal_error:
- { \__keyval_split_other:w ##3 = \s__keyval_stop ##2 }
- }
- {
- \__keyval_if_has_equal_active:w ##3 #2 \s__keyval_stop
- \__keyval_has_false:w \s__keyval_mark \s__keyval_stop \use_i:nn
- { \__keyval_split_active:w ##3 #2 \s__keyval_stop ##2 }
- {
- \__keyval_if_blank:w ##3 \s__keyval_nil \s__keyval_stop
- \__keyval_blank_true:w \s__keyval_mark \s__keyval_stop \use:n
- { \__keyval_trim:nN { ##3 } \__keyval_key:nN ##1 }
- }
- }
+ \__keyval_end_loop_other:w \s__keyval_tail
+ \__keyval_split_active:w ##3 \s__keyval_nil
+ \s__keyval_mark \__keyval_split_active_auxi:w
+ #2 \s__keyval_mark \__keyval_clean_up_active:w
+ \s__keyval_stop
+ ##1 ##2
\__keyval_loop_other:NNw ##1 ##2 \s__keyval_mark
}
- \cs_new:Npn \__keyval_split_active:w ##1 #2
- { \__keyval_trim:nN { ##1 } \__keyval_split_active:nw \s__keyval_mark }
- \cs_new:Npn \__keyval_split_active:nw ##1 ##2 #2 ##3 \s__keyval_stop
+ \cs_new:Npn \__keyval_split_active_auxi:w ##1 \s__keyval_stop
+ {
+ \__keyval_split_other:w ##1 \s__keyval_nil
+ \s__keyval_mark \__keyval_misplaced_equal_after_active_error:w
+ = \s__keyval_mark \__keyval_split_active_auxii:w
+ \s__keyval_stop
+ }
+ \cs_new:Npn \__keyval_split_active_auxii:w
+ ##1 \s__keyval_nil \s__keyval_mark \__keyval_misplaced_equal_after_active_error:w
+ \s__keyval_stop \s__keyval_mark
+ { \__keyval_trim:nN { ##1 } \__keyval_split_active_auxiii:w }
+ \cs_new:Npn \__keyval_split_active_auxiii:w ##1 ##2 \s__keyval_nil
+ {
+ \__keyval_split_active:w ##2 \s__keyval_nil
+ \s__keyval_mark \__keyval_misplaced_equal_in_split_error:w
+ #2 \s__keyval_mark \__keyval_split_active_auxiv:w
+ \s__keyval_stop
+ { ##1 }
+ }
+ \cs_new:Npn \__keyval_split_active_auxiv:w
+ ##1 \s__keyval_nil \s__keyval_mark \__keyval_misplaced_equal_in_split_error:w
+ \s__keyval_stop \s__keyval_mark
+ {
+ \__keyval_split_other:w ##1 \s__keyval_nil
+ \s__keyval_mark \__keyval_misplaced_equal_in_split_error:w
+ = \s__keyval_mark \__keyval_split_active_auxv:w
+ \s__keyval_stop
+ }
+ \cs_new:Npn \__keyval_split_active_auxv:w
+ ##1 \s__keyval_nil \s__keyval_mark \__keyval_misplaced_equal_in_split_error:w
+ \s__keyval_stop \s__keyval_mark
+ { \__keyval_trim:nN { ##1 } \__keyval_pair:nnNN }
+ \cs_new:Npn \__keyval_clean_up_active:w
+ ##1 \s__keyval_nil \s__keyval_mark \__keyval_split_active_auxi:w \s__keyval_stop \s__keyval_mark
+ {
+ \__keyval_split_other:w ##1 \s__keyval_nil
+ \s__keyval_mark \__keyval_split_other_auxi:w
+ = \s__keyval_mark \__keyval_clean_up_other:w
+ \s__keyval_stop
+ }
+ \cs_new:Npn \__keyval_split_other_auxi:w ##1 \s__keyval_stop
+ { \__keyval_trim:nN { ##1 } \__keyval_split_other_auxii:w }
+ \cs_new:Npn \__keyval_split_other_auxii:w ##1 ##2 \s__keyval_nil
+ {
+ \__keyval_split_other:w ##2 \s__keyval_nil
+ \s__keyval_mark \__keyval_misplaced_equal_in_split_error:w
+ = \s__keyval_mark \__keyval_split_other_auxiii:w
+ \s__keyval_stop
+ { ##1 }
+ }
+ \cs_new:Npn \__keyval_split_other_auxiii:w
+ ##1 \s__keyval_nil \s__keyval_mark \__keyval_misplaced_equal_in_split_error:w
+ \s__keyval_stop \s__keyval_mark
+ { \__keyval_trim:nN { ##1 } \__keyval_pair:nnNN }
+ \cs_new:Npn \__keyval_clean_up_other:w
+ ##1 \s__keyval_nil \s__keyval_mark \__keyval_split_other_auxi:w \s__keyval_stop \s__keyval_mark
+ {
+ \__keyval_if_blank:w ##1 \s__keyval_nil \s__keyval_stop \__keyval_blank_true:w
+ \s__keyval_mark \s__keyval_stop \use:n
+ { \__keyval_trim:nN { ##1 } \__keyval_key:nNN }
+ }
+ \cs_new:Npn \__keyval_misplaced_equal_after_active_error:w
+ \s__keyval_mark ##1 \s__keyval_stop \s__keyval_mark ##2 \s__keyval_nil
+ \s__keyval_mark ##3 \s__keyval_nil ##4 ##5
+ {
+ \__kernel_msg_expandable_error:nn
+ { kernel } { misplaced-equals-sign }
+ }
+ \cs_new:Npn \__keyval_misplaced_equal_in_split_error:w
+ \s__keyval_mark ##1 \s__keyval_stop \s__keyval_mark ##2 \s__keyval_nil
+ ##3 ##4 ##5
{
- \__keyval_if_empty:w \s__keyval_mark ##3 \s__keyval_stop
- \__keyval_has_false:w \s__keyval_mark \s__keyval_stop \use_i:nn
- { \__keyval_misplaced_equal_error: \use_none:n }
- { \__keyval_trim:nN { ##2 } \__keyval_key_val:nnN { ##1 } }
+ \__kernel_msg_expandable_error:nn
+ { kernel } { misplaced-equals-sign }
}
- \cs_new:Npn \__keyval_if_has_equal_active:w ##1 #2
- { \__keyval_if_empty:w \s__keyval_mark }
+ \cs_new:Npn \__keyval_end_loop_other:w
+ \s__keyval_tail
+ \__keyval_split_active:w ##1 \s__keyval_nil
+ \s__keyval_mark \__keyval_split_active_auxi:w
+ #2 \s__keyval_mark \__keyval_clean_up_active:w
+ \s__keyval_stop
+ ##2 ##3
+ \__keyval_loop_other:NNw ##4 \s__keyval_mark
+ { }
+ \cs_new:Npn \__keyval_end_loop_active:w
+ \s__keyval_tail
+ \__keyval_loop_other:NNw ##1 , \s__keyval_tail ,
+ \__keyval_loop_active:NNw ##2 \s__keyval_mark
+ { }
}
\char_set_catcode_active:n { `\, }
\char_set_catcode_active:n { `\= }
\__keyval_tmp:NN , =
\group_end:
-\cs_new:Npn \__keyval_end_loop_active:w
- \s__keyval_mark \s__keyval_tail
- \__keyval_loop_other:NNw #1 , \s__keyval_tail ,
- \__keyval_loop_active:NNw #2 \s__keyval_mark
- { }
-\cs_new:Npn \__keyval_end_loop_other:w
- \s__keyval_mark \s__keyval_tail
- \__keyval_if_has_equal_other:w #1 = \s__keyval_stop
- \__keyval_has_false:w \s__keyval_mark \s__keyval_stop \use_i:nn
- #2
- \__keyval_loop_other:NNw #3 \s__keyval_mark
- { }
-\cs_new:Npn \__keyval_split_other:w #1 =
- { \__keyval_trim:nN { #1 } \__keyval_split_other:nw \s__keyval_mark }
-\cs_new:Npn \__keyval_split_other:nw #1 #2 = #3 \s__keyval_stop
- {
- \__keyval_if_empty:w \s__keyval_mark #3 \s__keyval_stop
- \__keyval_has_false:w \s__keyval_mark \s__keyval_stop \use_i:nn
- { \__keyval_misplaced_equal_error: \use_none:n }
- { \__keyval_trim:nN { #2 } \__keyval_key_val:nnN { #1 } }
- }
-\cs_new:Npn \__keyval_key:nN #1 #2
- { \exp_not:n { #2 { #1 } } }
-\cs_new:Npn \__keyval_key_val:nnN #1 #2 #3
- {
- \__keyval_if_empty:w \s__keyval_mark #2 \s__keyval_stop
- \__keyval_empty_key:w \s__keyval_mark \s__keyval_stop
- \exp_not:n { #3 { #2 } { #1 } }
- }
-\cs_new:Npn \__keyval_if_empty:w #1 \s__keyval_mark \s__keyval_stop {}
+\cs_new:Npn \__keyval_pair:nnNN #1 #2 #3 #4
+ {
+ \__keyval_if_blank:w \s__keyval_mark #2 \s__keyval_nil \s__keyval_stop \__keyval_blank_key_error:w
+ \s__keyval_mark \s__keyval_stop
+ \exp_not:n { #4 { #2 } { #1 } }
+ }
+\cs_new:Npn \__keyval_key:nNN #1 #2 #3
+ {
+ \__keyval_if_blank:w \s__keyval_mark #1 \s__keyval_nil \s__keyval_stop \__keyval_blank_key_error:w
+ \s__keyval_mark \s__keyval_stop
+ \exp_not:n { #2 { #1 } }
+ }
+\cs_new:Npn \__keyval_if_empty:w #1 \s__keyval_mark \s__keyval_stop { }
\cs_new:Npn \__keyval_if_blank:w \s__keyval_mark #1 { \__keyval_if_empty:w \s__keyval_mark }
-\cs_new:Npn \__keyval_if_recursion_tail:w #1 \s__keyval_mark \s__keyval_tail {}
-\cs_new:Npn \__keyval_has_false:w \s__keyval_mark \s__keyval_stop \use_i:nn #1 #2 { #2 }
-\cs_new:Npn \__keyval_blank_true:w \s__keyval_mark \s__keyval_stop \use:n #1 {}
-\cs_new:Npn \__keyval_empty_key:w \s__keyval_mark \s__keyval_stop \exp_not:n #1
- { \__keyval_misplaced_equal_error: }
-\cs_new:Npn \__keyval_if_has_equal_other:w #1 =
- { \__keyval_if_empty:w \s__keyval_mark }
-\cs_new:Npn \__keyval_misplaced_equal_error:
- { \__kernel_msg_expandable_error:nn { kernel } { misplaced-equals-sign } }
+\cs_new:Npn \__keyval_if_recursion_tail:w \s__keyval_mark #1 \s__keyval_tail { }
+\cs_new:Npn \__keyval_blank_true:w \s__keyval_mark \s__keyval_stop \use:n #1 #2 #3 { }
+\cs_new:Npn \__keyval_blank_key_error:w \s__keyval_mark \s__keyval_stop \exp_not:n #1
+ {
+ \__kernel_msg_expandable_error:nn
+ { kernel } { blank-key-name }
+ }
\__kernel_msg_new:nnn { kernel } { misplaced-equals-sign }
{ Misplaced~equals~sign~in~key-value~input~\msg_line_context: }
+\__kernel_msg_new:nnn { kernel } { blank-key-name }
+ { Blank~key~name~in~key-value~input~\msg_line_context: }
\group_begin:
\cs_set_protected:Npn \__keyval_tmp:n #1
{
@@ -12912,7 +12964,7 @@
\__keyval_trim_auxi:w
##1
\s__keyval_nil
- \s__keyval_mark #1 {}
+ \s__keyval_mark #1 { }
\s__keyval_mark \__keyval_trim_auxii:w
\__keyval_trim_auxiii:w
#1 \s__keyval_nil
@@ -13005,11 +13057,11 @@
\cs_if_exist:cTF { \c__keys_props_root_str \l__keys_property_str }
{ \__keys_define_code:n {#2} }
{
- \str_if_empty:NF \l__keys_property_str
- {
- \__kernel_msg_error:nnxx { kernel } { key-property-unknown }
- { \l__keys_property_str } { \l_keys_path_str }
- }
+ \str_if_empty:NF \l__keys_property_str
+ {
+ \__kernel_msg_error:nnxx { kernel } { key-property-unknown }
+ { \l__keys_property_str } { \l_keys_path_str }
+ }
}
}
\cs_new_protected:Npn \__keys_property_find:n #1
@@ -13772,7 +13824,7 @@
}
{
\__kernel_msg_error:nnxx { kernel } { key-unknown }
- { \l_keys_path_str } { \l__keys_module_str }
+ { \l_keys_path_str } { \l__keys_module_str }
}
}
}
diff --git a/Master/texmf-dist/tex/latex/l3kernel/expl3-generic.tex b/Master/texmf-dist/tex/latex/l3kernel/expl3-generic.tex
index ca20bd595a7..d81e7eafb3a 100644
--- a/Master/texmf-dist/tex/latex/l3kernel/expl3-generic.tex
+++ b/Master/texmf-dist/tex/latex/l3kernel/expl3-generic.tex
@@ -19,7 +19,7 @@
%% and all files in that bundle must be distributed together.
%%
%% File: expl3.dtx
-\def\ExplFileDate{2020-05-11}%
+\def\ExplFileDate{2020-05-14}%
\let\ExplLoaderFileDate\ExplFileDate
\begingroup
\def\tempa{LaTeX2e}%
diff --git a/Master/texmf-dist/tex/latex/l3kernel/expl3.ltx b/Master/texmf-dist/tex/latex/l3kernel/expl3.ltx
index 0cf5f0fd3a1..e65631921ef 100644
--- a/Master/texmf-dist/tex/latex/l3kernel/expl3.ltx
+++ b/Master/texmf-dist/tex/latex/l3kernel/expl3.ltx
@@ -19,7 +19,7 @@
%% and all files in that bundle must be distributed together.
%%
%% File: expl3.dtx
-\def\ExplFileDate{2020-05-11}%
+\def\ExplFileDate{2020-05-14}%
\let\ExplLoaderFileDate\ExplFileDate
\everyjob\expandafter{\the\everyjob
\message{L3 programming layer <\ExplFileDate>}%
diff --git a/Master/texmf-dist/tex/latex/l3kernel/expl3.sty b/Master/texmf-dist/tex/latex/l3kernel/expl3.sty
index b962ab36e6e..ad6f7625caf 100644
--- a/Master/texmf-dist/tex/latex/l3kernel/expl3.sty
+++ b/Master/texmf-dist/tex/latex/l3kernel/expl3.sty
@@ -19,7 +19,7 @@
%% and all files in that bundle must be distributed together.
%%
%% File: expl3.dtx
-\def\ExplFileDate{2020-05-11}%
+\def\ExplFileDate{2020-05-14}%
\let\ExplLoaderFileDate\ExplFileDate
\ProvidesPackage{expl3}
[%
diff --git a/Master/texmf-dist/tex/latex/l3packages/l3keys2e/l3keys2e.sty b/Master/texmf-dist/tex/latex/l3packages/l3keys2e/l3keys2e.sty
index e0cce58db24..940a32e1864 100644
--- a/Master/texmf-dist/tex/latex/l3packages/l3keys2e/l3keys2e.sty
+++ b/Master/texmf-dist/tex/latex/l3packages/l3keys2e/l3keys2e.sty
@@ -32,7 +32,7 @@
}%
\endinput
}
-\ProvidesExplPackage{l3keys2e}{2020-03-06}{}
+\ProvidesExplPackage{l3keys2e}{2020-05-14}{}
{LaTeX2e option processing using LaTeX3 keys}
\cs_generate_variant:Nn \clist_put_right:Nn { Nv }
\cs_generate_variant:Nn \keys_if_exist:nnT { nx }
@@ -118,8 +118,8 @@
}
}
\cs_new:Npn \__keys_latexe_remove_equals:n #1
- { \__keys_latexe_remove_equals:w #1 = \q_stop }
-\cs_new:Npn \__keys_latexe_remove_equals:w #1 = #2 \q_stop { \exp_not:n {#1} }
+ { \__keys_latexe_remove_equals:w #1 = \s__keys_stop }
+\cs_new:Npn \__keys_latexe_remove_equals:w #1 = #2 \s__keys_stop { \exp_not:n {#1} }
\cs_new_protected:Npn \ProcessKeysOptions #1
{
\bool_set_true:N \l__keys_process_class_bool
diff --git a/Master/texmf-dist/tex/latex/l3packages/xfp/xfp.sty b/Master/texmf-dist/tex/latex/l3packages/xfp/xfp.sty
index f7e5e0c3cdc..8c3291ace47 100644
--- a/Master/texmf-dist/tex/latex/l3packages/xfp/xfp.sty
+++ b/Master/texmf-dist/tex/latex/l3packages/xfp/xfp.sty
@@ -33,7 +33,7 @@
\endinput
}
\RequirePackage{xparse}
-\ProvidesExplPackage{xfp}{2020-03-06}{}
+\ProvidesExplPackage{xfp}{2020-05-14}{}
{L3 Floating point unit}
\NewExpandableDocumentCommand \fpeval { m } { \fp_eval:n {#1} }
\NewExpandableDocumentCommand \inteval { m } { \int_eval:n {#1} }
diff --git a/Master/texmf-dist/tex/latex/l3packages/xfrac/xfrac.sty b/Master/texmf-dist/tex/latex/l3packages/xfrac/xfrac.sty
index ef55f9d5fec..37159c3cd8a 100644
--- a/Master/texmf-dist/tex/latex/l3packages/xfrac/xfrac.sty
+++ b/Master/texmf-dist/tex/latex/l3packages/xfrac/xfrac.sty
@@ -34,7 +34,7 @@
\endinput
}
\RequirePackage{amstext,graphicx,l3keys2e,textcomp,xparse,xtemplate}
-\ProvidesExplPackage{xfrac}{2020-03-06}{}
+\ProvidesExplPackage{xfrac}{2020-05-14}{}
{L3 Experimental split-level fractions}
\keys_define:nn { xfrac }
{
diff --git a/Master/texmf-dist/tex/latex/l3packages/xparse/xparse-generic.tex b/Master/texmf-dist/tex/latex/l3packages/xparse/xparse-generic.tex
new file mode 100644
index 00000000000..ef8e0b656aa
--- /dev/null
+++ b/Master/texmf-dist/tex/latex/l3packages/xparse/xparse-generic.tex
@@ -0,0 +1,2283 @@
+%%
+%% This is file `xparse-generic.tex',
+%% generated with the docstrip utility.
+%%
+%% The original source files were:
+%%
+%% xparse.dtx (with options: `core')
+%%
+%% Copyright (C) 2009-2020 The LaTeX3 Project
+%%
+%% It may be distributed and/or modified under the conditions of
+%% the LaTeX Project Public License (LPPL), either version 1.3c of
+%% this license or (at your option) any later version. The latest
+%% version of this license is in the file:
+%%
+%% http://www.latex-project.org/lppl.txt
+%%
+%% This file is part of the "l3packages bundle" (The Work in LPPL)
+%% and all files in that bundle must be distributed together.
+%%
+%% File: xparse.dtx
+\cs_if_exist:NT \NewDocumentCommand
+ { \file_input_stop: }
+\if_charcode:w xx
+ \cs_new:Npn \__xparse_file_end_hook: { }
+\else
+ \ExplSyntaxOn
+ \cs_new:Npn \__xparse_file_end_hook: { \ExplSyntaxOff }
+\fi:
+\tl_new:N \l__xparse_arg_spec_tl
+\tl_new:N \l__xparse_args_tl
+\tl_new:N \l__xparse_args_i_tl
+\tl_new:N \l__xparse_args_ii_tl
+\int_new:N \l__xparse_current_arg_int
+\bool_new:N \l__xparse_defaults_bool
+\tl_new:N \l__xparse_defaults_tl
+\bool_new:N \l__xparse_environment_bool
+\str_new:N \l__xparse_environment_str
+\bool_new:N \l__xparse_expandable_bool
+\tl_new:N \l__xparse_expandable_aux_name_tl
+\tl_set:Nn \l__xparse_expandable_aux_name_tl
+ {
+ \l__xparse_function_tl \c_space_tl
+ ( arg~ \int_use:N \l__xparse_current_arg_int )
+ }
+\int_new:N \g__xparse_grabber_int
+\tl_new:N \l__xparse_fn_tl
+\tl_new:N \l__xparse_fn_code_tl
+\tl_new:N \l__xparse_function_tl
+\bool_new:N \l__xparse_grab_expandably_bool
+\bool_new:N \l__xparse_obey_spaces_bool
+\tl_new:N \l__xparse_last_delimiters_tl
+\bool_new:N \l__xparse_long_bool
+\int_new:N \l__xparse_m_args_int
+\bool_new:N \l__xparse_prefixed_bool
+\tl_new:N \l__xparse_process_all_tl
+\tl_new:N \l__xparse_process_one_tl
+\bool_new:N \l__xparse_process_some_bool
+\tl_new:N \l__xparse_saved_args_tl
+\tl_new:N \l__xparse_signature_tl
+\bool_new:N \l__xparse_some_obey_spaces_bool
+\bool_new:N \l__xparse_some_long_bool
+\bool_new:N \l__xparse_some_short_bool
+\prop_new:N \l__xparse_tmp_prop
+\tl_new:N \l__xparse_tmpa_tl
+\tl_new:N \l__xparse_tmpb_tl
+\cs_new_eq:NN \__xparse_tmp:w ?
+\cs_new_protected:Npn \__xparse_declare_cmd:Nnn
+ {
+ \bool_set_false:N \l__xparse_expandable_bool
+ \__xparse_declare_cmd_aux:Nnn
+ }
+\cs_new_protected:Npn \__xparse_declare_expandable_cmd:Nnn
+ {
+ \bool_set_true:N \l__xparse_expandable_bool
+ \__xparse_declare_cmd_aux:Nnn
+ }
+\cs_new_protected:Npn \__xparse_declare_cmd_aux:Nnn #1#2#3
+ {
+ \cs_if_exist:NTF #1
+ {
+ \__kernel_msg_info:nnxx { xparse } { redefine-command }
+ { \token_to_str:N #1 } { \tl_to_str:n {#2} }
+ }
+ {
+ \bool_lazy_or:nnT
+ { \cs_if_exist_p:c { \cs_to_str:N #1 ~ code } }
+ { \cs_if_exist_p:c { \cs_to_str:N #1 ~ defaults } }
+ {
+ \__kernel_msg_warning:nnx { xparse } { unsupported-let }
+ { \token_to_str:N #1 }
+ }
+ \__kernel_msg_info:nnxx { xparse } { define-command }
+ { \token_to_str:N #1 } { \tl_to_str:n {#2} }
+ }
+ \bool_set_false:N \l__xparse_environment_bool
+ \__xparse_declare_cmd_internal:Nnnn #1 {#2} {#3} { }
+ }
+\cs_new_protected:Npn \__xparse_declare_cmd_internal:Nnnn #1#2#3#4
+ {
+ \tl_set:Nx \l__xparse_function_tl { \cs_to_str:N #1 }
+ \tl_set:Nx \l__xparse_fn_tl
+ { \exp_not:c { \l__xparse_function_tl \c_space_tl } }
+ \__xparse_normalize_arg_spec:n {#2}
+ \exp_args:No \__xparse_prepare_signature:n \l__xparse_arg_spec_tl
+ \__xparse_declare_cmd_code:Nnn #1 {#2} {#3}
+ #4
+ \__xparse_break_point:n {#2}
+ }
+\cs_generate_variant:Nn \__xparse_declare_cmd_internal:Nnnn { cnx }
+\cs_new_eq:NN \__xparse_break_point:n \use_none:n
+\cs_new_protected:Npn \__xparse_declare_cmd_code:Nnn
+ {
+ \bool_if:NTF \l__xparse_grab_expandably_bool
+ { \__xparse_declare_cmd_code_expandable:Nnn }
+ { \__xparse_declare_cmd_code_aux:Nnn }
+ }
+\cs_new_protected:Npn \__xparse_declare_cmd_code_aux:Nnn #1#2#3
+ {
+ \cs_generate_from_arg_count:cNnn
+ { \l__xparse_function_tl \c_space_tl code }
+ \cs_set_protected:Npn \l__xparse_current_arg_int {#3}
+ \cs_set_protected_nopar:Npx #1
+ {
+ \bool_if:NTF \l__xparse_environment_bool
+ {
+ \__xparse_start_env:nnnnn { \exp_not:n {#2} }
+ { \l__xparse_environment_str }
+ }
+ {
+ \__xparse_start:nNNnnn { \exp_not:n {#2} }
+ \exp_not:c { \l__xparse_function_tl \c_space_tl }
+ \exp_not:c { \l__xparse_function_tl \c_space_tl code }
+ }
+ { \exp_not:o \l__xparse_signature_tl }
+ {
+ \bool_if:NT \l__xparse_defaults_bool
+ { \exp_not:o \l__xparse_defaults_tl }
+ }
+ {
+ \bool_if:NT \l__xparse_process_some_bool
+ { \exp_not:o \l__xparse_process_all_tl }
+ }
+ }
+ }
+\cs_new_protected:Npn \__xparse_declare_cmd_code_expandable:Nnn #1#2#3
+ {
+ \exp_args:Ncc \cs_generate_from_arg_count:NNnn
+ { \l__xparse_function_tl \c_space_tl code }
+ { cs_set \bool_if:NF \l__xparse_expandable_bool { _protected } :Npn }
+ \l__xparse_current_arg_int {#3}
+ \bool_if:NT \l__xparse_defaults_bool
+ {
+ \use:x
+ {
+ \cs_generate_from_arg_count:cNnn
+ { \l__xparse_function_tl \c_space_tl defaults }
+ \cs_set:Npn \l__xparse_current_arg_int
+ { \exp_not:o \l__xparse_defaults_tl }
+ }
+ }
+ \bool_if:NTF \l__xparse_expandable_bool
+ { \cs_set_nopar:Npx } { \cs_set_protected_nopar:Npx } #1
+ {
+ \exp_not:N \__xparse_start_expandable:nNNNNn
+ { \exp_not:n {#2} }
+ \exp_not:c { \l__xparse_function_tl \c_space_tl }
+ \exp_not:c
+ {
+ \l__xparse_function_tl \c_space_tl
+ \bool_if:NT \l__xparse_some_short_bool
+ { \bool_if:NT \l__xparse_some_long_bool { \c_space_tl } }
+ }
+ \exp_not:c { \l__xparse_function_tl \c_space_tl code }
+ \bool_if:NTF \l__xparse_defaults_bool
+ { \exp_not:c { \l__xparse_function_tl \c_space_tl defaults } }
+ { ? }
+ { \exp_not:o \l__xparse_signature_tl }
+ }
+ \bool_if:NTF \l__xparse_some_long_bool
+ {
+ \bool_if:NT \l__xparse_some_short_bool
+ {
+ \cs_set_nopar:cpx { \l__xparse_function_tl \c_space_tl \c_space_tl }
+ ##1##2 { ##1 {##2} }
+ }
+ \cs_set:cpx
+ }
+ { \cs_set_nopar:cpx }
+ { \l__xparse_function_tl \c_space_tl } ##1##2 { ##1 {##2} }
+ }
+\cs_new_protected:Npn \__xparse_declare_env:nnnn #1#2
+ {
+ \str_set:Nx \l__xparse_environment_str {#1}
+ \str_set:Nx \l__xparse_environment_str
+ { \tl_trim_spaces:o { \l__xparse_environment_str } }
+ \cs_if_exist:cTF { \l__xparse_environment_str }
+ {
+ \__kernel_msg_info:nnxx { xparse } { redefine-environment }
+ { \l__xparse_environment_str } { \tl_to_str:n {#2} }
+ }
+ {
+ \__kernel_msg_info:nnxx { xparse } { define-environment }
+ { \l__xparse_environment_str } { \tl_to_str:n {#2} }
+ }
+ \bool_set_false:N \l__xparse_expandable_bool
+ \bool_set_true:N \l__xparse_environment_bool
+ \exp_args:NV \__xparse_declare_env_internal:nnnn
+ \l__xparse_environment_str {#2}
+ }
+\cs_new_protected:Npn \__xparse_declare_env_internal:nnnn #1#2#3#4
+ {
+ \__xparse_declare_cmd_internal:cnxn { environment~ #1 } {#2}
+ {
+ \cs_set_nopar:Npx \exp_not:c { environment~ #1 ~end~aux }
+ {
+ \exp_not:N \exp_not:N \exp_not:c { environment~ #1~end~aux~ }
+ \exp_not:n { \exp_not:o \l__xparse_args_tl }
+ }
+ \exp_not:n {#3}
+ }
+ {
+ \cs_set_nopar:cpx { environment~ #1 ~end }
+ { \exp_not:c { environment~ #1 ~end~aux } }
+ \cs_generate_from_arg_count:cNnn
+ { environment~ #1 ~end~aux~ } \cs_set:Npn
+ \l__xparse_current_arg_int {#4}
+ \cs_set_eq:cc {#1} { environment~ #1 }
+ \cs_set_eq:cc { end #1 } { environment~ #1 ~end }
+ }
+ }
+\cs_new_protected:Npn \__xparse_start_env:nnnnn #1#2
+ {
+ \cs_if_exist_use:N \conditionally@traceoff
+ \str_set:Nn \l__xparse_environment_str {#2}
+ \bool_set_true:N \l__xparse_environment_bool
+ \__xparse_start_aux:ccnnnn
+ { environment~ \l__xparse_environment_str \c_space_tl }
+ { environment~ \l__xparse_environment_str \c_space_tl code }
+ {#1}
+ }
+\cs_new_protected:Npx \__xparse_start:nNNnnn #1#2#3
+ {
+ \exp_not:n { \cs_if_exist_use:N \conditionally@traceoff }
+ \exp_not:c { xparse~function~is~not~expandable }
+ \exp_not:n { \bool_set_false:N \l__xparse_environment_bool }
+ \exp_not:N \__xparse_start_aux:NNnnnn
+ #2 #3 {#1}
+ }
+\cs_new_protected:Npn \__xparse_start_aux:NNnnnn #1#2#3#4#5#6
+ {
+ \tl_clear:N \l__xparse_args_tl
+ \tl_set:Nn \l__xparse_fn_tl {#1}
+ \tl_set:Nn \l__xparse_fn_code_tl {#2}
+ \tl_set:Nn \l__xparse_defaults_tl {#5}
+ \tl_set:Nn \l__xparse_process_all_tl {#6}
+ #4 \__xparse_run_code:
+ }
+\cs_generate_variant:Nn \__xparse_start_aux:NNnnnn { cc }
+\cs_new_protected:Npn \__xparse_run_code:
+ {
+ \tl_if_empty:NF \l__xparse_defaults_tl { \__xparse_defaults: }
+ \tl_if_empty:NF \l__xparse_process_all_tl { \__xparse_args_process: }
+ \cs_if_exist_use:N \conditionally@traceon
+ \exp_after:wN \l__xparse_fn_code_tl \l__xparse_args_tl
+ }
+\cs_new_protected:Npn \__xparse_defaults:
+ {
+ \__xparse_defaults_def:
+ \tl_set_eq:NN \l__xparse_args_i_tl \l__xparse_args_tl
+ \__xparse_defaults_aux: \__xparse_defaults_aux: \__xparse_defaults_aux:
+ \__xparse_defaults_aux: \__xparse_defaults_aux: \__xparse_defaults_aux:
+ \__xparse_defaults_aux: \__xparse_defaults_aux: \__xparse_defaults_aux:
+ \__xparse_defaults_error:w
+ \q_recursion_stop
+ \tl_set_eq:NN \l__xparse_args_tl \l__xparse_args_i_tl
+ }
+\cs_new_protected:Npn \__xparse_defaults_aux:
+ {
+ \tl_set:Nx \l__xparse_args_ii_tl
+ { \exp_after:wN \__xparse_tmp:w \l__xparse_args_i_tl }
+ \tl_if_eq:NNT \l__xparse_args_ii_tl \l__xparse_args_i_tl
+ { \use_none_delimit_by_q_recursion_stop:w }
+ \tl_set_eq:NN \l__xparse_args_i_tl \l__xparse_args_ii_tl
+ }
+\cs_new_protected:Npn \__xparse_defaults_error:w \q_recursion_stop
+ {
+ \__kernel_msg_error:nnx { xparse } { loop-in-defaults }
+ { \__xparse_environment_or_command: }
+ }
+\cs_new_protected:Npn \__xparse_defaults_def:
+ {
+ \tl_clear:N \l__xparse_tmpa_tl
+ \int_zero:N \l__xparse_current_arg_int
+ \__xparse_tl_mapthread_function:NNN \l__xparse_args_tl \l__xparse_defaults_tl
+ \__xparse_defaults_def:nn
+ \cs_generate_from_arg_count:NNVo \__xparse_tmp:w \cs_set:Npn
+ \l__xparse_current_arg_int \l__xparse_tmpa_tl
+ }
+\cs_generate_variant:Nn \cs_generate_from_arg_count:NNnn { NNVo }
+\cs_new_protected:Npn \__xparse_defaults_def:nn
+ {
+ \int_incr:N \l__xparse_current_arg_int
+ \exp_args:NV \__xparse_defaults_def:nnn \l__xparse_current_arg_int
+ }
+\cs_new_protected:Npn \__xparse_defaults_def:nnn #1#2#3
+ {
+ \tl_put_right:Nx \l__xparse_tmpa_tl
+ {
+ {
+ \exp_not:N \exp_not:n
+ {
+ \tl_if_novalue:nTF {#2}
+ { \exp_not:o {#3} }
+ { \exp_not:n { ## #1 } }
+ }
+ }
+ }
+ }
+\cs_new_protected:Npn \__xparse_args_process:
+ {
+ \tl_clear:N \l__xparse_args_ii_tl
+ \__xparse_tl_mapthread_function:NNN
+ \l__xparse_args_tl
+ \l__xparse_process_all_tl
+ \__xparse_args_process_loop:nn
+ \tl_set_eq:NN \l__xparse_args_tl \l__xparse_args_ii_tl
+ }
+\cs_new_protected:Npn \__xparse_args_process_loop:nn #1#2
+ {
+ \tl_set:Nn \ProcessedArgument {#1}
+ \tl_if_novalue:nF {#1}
+ { \tl_map_function:nN {#2} \__xparse_args_process_aux:n }
+ \tl_put_right:No \l__xparse_args_ii_tl
+ { \exp_after:wN { \ProcessedArgument } }
+ }
+\cs_new_protected:Npn \__xparse_args_process_aux:n #1
+ {
+ \cs_generate_from_arg_count:NNnn \__xparse_tmp:w \cs_set:Npn
+ { \tl_count:N \l__xparse_args_tl } {#1}
+ \exp_args:NNNo \exp_after:wN \__xparse_tmp:w \l__xparse_args_tl
+ { \ProcessedArgument }
+ }
+\cs_new:Npn \__xparse_start_expandable:nNNNNn #1#2#3#4#5#6
+ { #6 \__xparse_end_expandable:NNw #5 #4 \q__xparse #2#3 }
+\cs_new:Npn \__xparse_end_expandable:NNw #1#2
+ { \__xparse_end_expandable_aux:w #1#2 \prg_do_nothing: }
+\cs_new:Npn \__xparse_end_expandable_aux:w #1#2#3 \q__xparse
+ { \exp_args:No \__xparse_end_expandable_aux:nNNNN {#3} #1 #2 }
+\cs_new:Npn \__xparse_end_expandable_aux:nNNNN #1#2#3#4#5
+ {
+ \token_if_eq_charcode:NNT ? #2 { \exp_after:wN \use_iv:nnnn }
+ \__xparse_end_expandable_defaults:nnnNNn {#1} { } {#1} #2#3
+ { } { } { } { } { } { } { } { } { } { }
+ {
+ \__kernel_msg_expandable_error:nnf
+ { xparse } { loop-in-defaults }
+ { \exp_args:Nf \tl_trim_spaces:n { \token_to_str:N #4 } }
+ \use_iv:nnnn
+ }
+ \q_stop
+ }
+\cs_new:Npn \__xparse_end_expandable_defaults:nnnNNn #1#2#3#4#5#6
+ {
+ #6
+ \str_if_eq:nnTF {#1} {#2}
+ { \use_i_delimit_by_q_stop:nw { #5 #1 } }
+ {
+ \exp_args:No \__xparse_tl_mapthread_function:nnN
+ { #4 #1 } {#3}
+ \__xparse_end_expandable_defaults:nnw
+ \__xparse_end_expandable_defaults:nnnNNn { } {#1} {#3} #4 #5
+ }
+ }
+\cs_new:Npn \__xparse_end_expandable_defaults:nnw #1#2
+ {
+ \tl_if_novalue:nTF {#2}
+ { \exp_args:No \__xparse_end_expandable_defaults:nw {#1} }
+ { \__xparse_end_expandable_defaults:nw {#2} }
+ }
+\cs_new:Npn \__xparse_end_expandable_defaults:nw
+ #1#2 \__xparse_end_expandable_defaults:nnnNNn #3
+ { #2 \__xparse_end_expandable_defaults:nnnNNn { #3 {#1} } }
+\cs_new_protected:Npn \__xparse_normalize_arg_spec:n #1
+ {
+ \int_zero:N \l__xparse_current_arg_int
+ \tl_clear:N \l__xparse_last_delimiters_tl
+ \tl_clear:N \l__xparse_arg_spec_tl
+ \bool_set_true:N \l__xparse_grab_expandably_bool
+ \bool_set_false:N \l__xparse_obey_spaces_bool
+ \bool_set_false:N \l__xparse_long_bool
+ \bool_set_false:N \l__xparse_some_obey_spaces_bool
+ \bool_set_false:N \l__xparse_some_long_bool
+ \bool_set_false:N \l__xparse_some_short_bool
+ \__xparse_normalize_arg_spec_loop:n #1
+ \q_recursion_tail \q_recursion_tail \q_recursion_tail \q_recursion_stop
+ \int_compare:nNnT \l__xparse_current_arg_int > 9
+ {
+ \__kernel_msg_error:nnxx { xparse } { too-many-arguments }
+ { \__xparse_environment_or_command: } { \tl_to_str:n {#1} }
+ \__xparse_bad_def:wn
+ }
+ \bool_if:NT \l__xparse_expandable_bool
+ {
+ \tl_if_empty:NF \l__xparse_last_delimiters_tl
+ {
+ \__kernel_msg_error:nnxx { xparse } { expandable-ending-optional }
+ { \iow_char:N \\ \l__xparse_function_tl } { \tl_to_str:n {#1} }
+ \__xparse_bad_def:wn
+ }
+ }
+ \bool_if:NT \l__xparse_expandable_bool
+ { \bool_set_true:N \l__xparse_grab_expandably_bool }
+ \bool_if:NT \l__xparse_environment_bool
+ { \bool_set_false:N \l__xparse_grab_expandably_bool }
+ }
+\cs_new_protected:Npn \__xparse_normalize_arg_spec_loop:n #1
+ {
+ \quark_if_recursion_tail_stop:n {#1}
+ \int_incr:N \l__xparse_current_arg_int
+ \cs_if_exist_use:cF { __xparse_normalize_type_ \tl_to_str:n {#1} :w }
+ {
+ \bool_lazy_any:nTF
+ {
+ { \str_if_eq_p:nn {#1} { G } }
+ { \str_if_eq_p:nn {#1} { g } }
+ { \str_if_eq_p:nn {#1} { l } }
+ { \str_if_eq_p:nn {#1} { u } }
+ }
+ {
+ \__kernel_msg_error:nnxx { xparse } { xparse-argument-type }
+ { \__xparse_environment_or_command: } { \tl_to_str:n {#1} }
+ }
+ {
+ \__kernel_msg_error:nnxx { xparse } { unknown-argument-type }
+ { \__xparse_environment_or_command: } { \tl_to_str:n {#1} }
+ }
+ \__xparse_bad_def:wn
+ }
+ }
+\cs_set_protected:Npn \__xparse_tmp:w #1
+ {
+ \cs_new_protected:Npn \__xparse_normalize_type_d:w ##1##2
+ {
+ \quark_if_recursion_tail_stop_do:nn {##2} { \__xparse_bad_arg_spec:wn }
+ \__xparse_normalize_type_D:w {##1} {##2} {#1}
+ }
+ \cs_new_protected:Npn \__xparse_normalize_type_e:w ##1
+ {
+ \quark_if_recursion_tail_stop_do:nn {##1} { \__xparse_bad_arg_spec:wn }
+ \__xparse_normalize_type_E:w {##1} { }
+ }
+ \cs_new_protected:Npn \__xparse_normalize_type_o:w
+ { \__xparse_normalize_type_D:w [ ] {#1} }
+ \cs_new_protected:Npn \__xparse_normalize_type_O:w
+ { \__xparse_normalize_type_D:w [ ] }
+ \cs_new_protected:Npn \__xparse_normalize_type_r:w ##1##2
+ {
+ \quark_if_recursion_tail_stop_do:nn {##2} { \__xparse_bad_arg_spec:wn }
+ \__xparse_normalize_type_R:w {##1} {##2} {#1}
+ }
+ \cs_new_protected:Npn \__xparse_normalize_type_s:w
+ { \__xparse_normalize_type_t:w * }
+ }
+\exp_args:No \__xparse_tmp:w { \c_novalue_tl }
+\cs_new_protected:cpn { __xparse_normalize_type_>:w } #1#2
+ {
+ \quark_if_recursion_tail_stop_do:nn {#2} { \__xparse_bad_arg_spec:wn }
+ \bool_if:NT \l__xparse_expandable_bool
+ {
+ \__kernel_msg_error:nnxx { xparse } { processor-in-expandable }
+ { \iow_char:N \\ \l__xparse_function_tl } { \tl_to_str:n {#1} }
+ \__xparse_bad_def:wn
+ }
+ \tl_put_right:Nx \l__xparse_arg_spec_tl { > { \tl_trim_spaces:n {#1} } }
+ \int_decr:N \l__xparse_current_arg_int
+ \bool_set_false:N \l__xparse_grab_expandably_bool
+ \__xparse_normalize_arg_spec_loop:n {#2}
+ }
+\cs_new_protected:cpn { __xparse_normalize_type_+:w } #1
+ {
+ \quark_if_recursion_tail_stop_do:nn {#1} { \__xparse_bad_arg_spec:wn }
+ \bool_if:NT \l__xparse_long_bool
+ {
+ \__kernel_msg_error:nnxx { xparse } { two-markers }
+ { \__xparse_environment_or_command: } { + }
+ \__xparse_bad_def:wn
+ }
+ \bool_set_true:N \l__xparse_long_bool
+ \int_decr:N \l__xparse_current_arg_int
+ \__xparse_normalize_arg_spec_loop:n {#1}
+ }
+\cs_new_protected:cpn { __xparse_normalize_type_!:w } #1
+ {
+ \quark_if_recursion_tail_stop_do:nn {#1} { \__xparse_bad_arg_spec:wn }
+ \bool_if:NT \l__xparse_obey_spaces_bool
+ {
+ \__kernel_msg_error:nnxx { xparse } { two-markers }
+ { \__xparse_environment_or_command: } { ! }
+ \__xparse_bad_def:wn
+ }
+ \bool_set_true:N \l__xparse_obey_spaces_bool
+ \bool_set_true:N \l__xparse_some_obey_spaces_bool
+ \int_decr:N \l__xparse_current_arg_int
+ \__xparse_normalize_arg_spec_loop:n {#1}
+ }
+\cs_new_protected:Npn \__xparse_normalize_type_D:w #1#2#3
+ {
+ \quark_if_recursion_tail_stop_do:nn {#3} { \__xparse_bad_arg_spec:wn }
+ \__xparse_single_token_check:n {#1} \__xparse_allowed_token_check:N #1
+ \__xparse_single_token_check:n {#2}
+ \__xparse_add_arg_spec:n { D #1 #2 {#3} }
+ \tl_put_right:Nn \l__xparse_last_delimiters_tl {#1}
+ \bool_set_false:N \l__xparse_grab_expandably_bool
+ \__xparse_normalize_arg_spec_loop:n
+ }
+\cs_new_protected:Npn \__xparse_normalize_type_E:w #1#2
+ {
+ \quark_if_recursion_tail_stop_do:nn {#2} { \__xparse_bad_arg_spec:wn }
+ \tl_if_blank:nT {#1} { \__xparse_bad_arg_spec:wn }
+ \tl_map_function:nN {#1} \__xparse_single_token_check:n
+ \tl_map_function:nN {#1} \__xparse_allowed_token_check:N
+ \__xparse_normalize_E_unique_check:w #1 \q_nil \q_stop
+ \int_compare:nNnT { \tl_count:n {#2} } > { \tl_count:n {#1} }
+ { \__xparse_bad_arg_spec:wn }
+ \__xparse_add_arg_spec:n { E {#1} {#2} }
+ \tl_put_right:Nn \l__xparse_last_delimiters_tl {#1}
+ \bool_set_false:N \l__xparse_grab_expandably_bool
+ \int_add:Nn \l__xparse_current_arg_int { \tl_count:n {#1} - 1 }
+ \__xparse_normalize_arg_spec_loop:n
+ }
+\cs_new_protected:Npn \__xparse_normalize_E_unique_check:w #1#2 \q_stop
+ {
+ \quark_if_nil:NF #1
+ {
+ \tl_if_in:nnT {#2} {#1} { \__xparse_bad_arg_spec:wn }
+ \__xparse_normalize_E_unique_check:w #2 \q_stop
+ }
+ }
+\cs_new_protected:Npn \__xparse_normalize_type_t:w #1
+ {
+ \quark_if_recursion_tail_stop_do:Nn #1 { \__xparse_bad_arg_spec:wn }
+ \__xparse_single_token_check:n {#1} \__xparse_allowed_token_check:N #1
+ \tl_put_right:Nx \l__xparse_arg_spec_tl
+ {
+ \bool_if:NT \l__xparse_obey_spaces_bool { ! }
+ t \exp_not:n {#1}
+ }
+ \tl_put_right:Nn \l__xparse_last_delimiters_tl {#1}
+ \bool_set_false:N \l__xparse_grab_expandably_bool
+ \bool_set_false:N \l__xparse_obey_spaces_bool
+ \bool_set_false:N \l__xparse_long_bool
+ \__xparse_normalize_arg_spec_loop:n
+ }
+\cs_new_protected:Npn \__xparse_normalize_type_m:w
+ {
+ \__xparse_delimiter_check:nnn { } { m } { \iow_char:N \{ }
+ \__xparse_add_arg_spec_mandatory:n { m }
+ \__xparse_normalize_arg_spec_loop:n
+ }
+\cs_new_protected:Npn \__xparse_normalize_type_R:w #1#2#3
+ {
+ \quark_if_recursion_tail_stop_do:nn {#3} { \__xparse_bad_arg_spec:wn }
+ \__xparse_single_token_check:n {#1} \__xparse_allowed_token_check:N #1
+ \__xparse_single_token_check:n {#2}
+ \__xparse_delimiter_check:nnn {#1} { R/r } { \tl_to_str:n {#1} }
+ \bool_set_false:N \l__xparse_grab_expandably_bool
+ \__xparse_add_arg_spec_mandatory:n { R #1 #2 {#3} }
+ \__xparse_normalize_arg_spec_loop:n
+ }
+\cs_new_protected:Npn \__xparse_normalize_type_v:w
+ {
+ \__xparse_normalize_check_gv:N v
+ \__xparse_add_arg_spec_mandatory:n { v }
+ \__xparse_normalize_arg_spec_loop:n
+ }
+\cs_new_protected:Npn \__xparse_normalize_type_b:w #1
+ {
+ \bool_if:NF \l__xparse_environment_bool
+ {
+ \__kernel_msg_error:nnxx
+ { xparse } { invalid-command-arg }
+ { \__xparse_environment_or_command: } { b }
+ \__xparse_bad_def:wn
+ }
+ \tl_clear:N \l__xparse_last_delimiters_tl
+ \__xparse_add_arg_spec:n { b }
+ \quark_if_recursion_tail_stop:n {#1}
+ \__kernel_msg_error:nnxx { xparse } { arg-after-body }
+ { \__xparse_environment_or_command: }
+ { \tl_to_str:n {#1} }
+ \__xparse_bad_def:wn
+ }
+\cs_new_protected:Npn \__xparse_single_token_check:n #1
+ {
+ \tl_trim_spaces_apply:nN {#1} \tl_if_single_token:nF
+ {
+ \__kernel_msg_error:nnxx { xparse } { not-single-token }
+ { \__xparse_environment_or_command: } { \tl_to_str:n {#1} }
+ \__xparse_bad_def:wn
+ }
+ }
+\cs_new_protected:Npn \__xparse_allowed_token_check:N #1
+ {
+ \token_if_eq_meaning:NNTF #1 \c_group_begin_token
+ { \use:n }
+ {
+ \token_if_eq_meaning:NNTF #1 \c_group_end_token
+ { \use:n }
+ { \use_none:n }
+ }
+ {
+ \__kernel_msg_error:nnxxx
+ { xparse } { forbidden-implicit-group-token }
+ { \__xparse_environment_or_command: } { \tl_to_str:n {#1} }
+ {
+ \token_if_eq_meaning:NNTF #1 \c_group_begin_token
+ { begin } { end }
+ }
+ \__xparse_bad_def:wn
+ }
+ }
+\cs_new_protected:Npn \__xparse_normalize_check_gv:N #1
+ {
+ \bool_if:NT \l__xparse_expandable_bool
+ {
+ \__kernel_msg_error:nnxx
+ { xparse } { invalid-expandable-argument-type }
+ { \iow_char:N \\ \l__xparse_function_tl } { \tl_to_str:n {#1} }
+ \__xparse_bad_def:wn
+ }
+ \bool_set_false:N \l__xparse_grab_expandably_bool
+ }
+\cs_new_protected:Npn \__xparse_normalize_check_lu:N #1
+ {
+ \bool_if:NT \l__xparse_expandable_bool
+ {
+ \tl_if_empty:NF \l__xparse_last_delimiters_tl
+ {
+ \__kernel_msg_error:nnxx
+ { xparse } { invalid-after-optional-expandably }
+ { \iow_char:N \\ \l__xparse_function_tl } { \tl_to_str:n {#1} }
+ \__xparse_bad_def:wn
+ }
+ }
+ }
+\cs_new_protected:Npn \__xparse_delimiter_check:nnn #1#2#3
+ {
+ \tl_map_inline:Nn \l__xparse_last_delimiters_tl
+ {
+ \tl_if_eq:nnT {##1} {#1}
+ {
+ \__kernel_msg_warning:nnxx { xparse } { optional-mandatory }
+ {#2} {#3}
+ }
+ }
+ }
+\cs_new_protected:Npn \__xparse_bad_arg_spec:wn #1 \__xparse_break_point:n #2
+ {
+ \__kernel_msg_error:nnxx { xparse } { bad-arg-spec }
+ { \__xparse_environment_or_command: } { \tl_to_str:n {#2} }
+ }
+\cs_new_protected:Npn \__xparse_bad_def:wn #1 \__xparse_break_point:n #2 { }
+\cs_new_protected:Npn \__xparse_add_arg_spec:n #1
+ {
+ \bool_lazy_and:nnT
+ { ! \l__xparse_long_bool }
+ { \l__xparse_some_long_bool }
+ {
+ \bool_if:NT \l__xparse_expandable_bool
+ {
+ \__kernel_msg_error:nnx { xparse } { inconsistent-long }
+ { \iow_char:N \\ \l__xparse_function_tl }
+ \__xparse_bad_def:wn
+ }
+ \bool_set_false:N \l__xparse_grab_expandably_bool
+ }
+ \bool_if:NTF \l__xparse_long_bool
+ { \bool_set_true:N \l__xparse_some_long_bool }
+ { \bool_set_true:N \l__xparse_some_short_bool }
+ \tl_put_right:Nx \l__xparse_arg_spec_tl
+ {
+ \bool_if:NT \l__xparse_long_bool { + }
+ \bool_if:NT \l__xparse_obey_spaces_bool { ! }
+ \exp_not:n {#1}
+ }
+ \bool_set_false:N \l__xparse_long_bool
+ \bool_set_false:N \l__xparse_obey_spaces_bool
+ }
+\cs_new_protected:Npn \__xparse_add_arg_spec_mandatory:n #1
+ {
+ \bool_if:NT \l__xparse_some_obey_spaces_bool
+ {
+ \__kernel_msg_error:nnxx { xparse } { non-trailing-obey-spaces }
+ { \__xparse_environment_or_command: } { \tl_to_str:n {#1} }
+ \__xparse_bad_def:wn
+ }
+ \tl_clear:N \l__xparse_last_delimiters_tl
+ \__xparse_add_arg_spec:n {#1}
+ }
+\cs_new_protected:Npn \__xparse_prepare_signature:n #1
+ {
+ \int_zero:N \l__xparse_current_arg_int
+ \bool_set_false:N \l__xparse_long_bool
+ \bool_set_false:N \l__xparse_obey_spaces_bool
+ \int_zero:N \l__xparse_m_args_int
+ \bool_set_false:N \l__xparse_defaults_bool
+ \tl_clear:N \l__xparse_defaults_tl
+ \tl_clear:N \l__xparse_process_all_tl
+ \tl_clear:N \l__xparse_process_one_tl
+ \bool_set_false:N \l__xparse_process_some_bool
+ \tl_clear:N \l__xparse_signature_tl
+ \__xparse_prepare_signature:N #1 \q_recursion_tail \q_recursion_stop
+ \bool_if:NF \l__xparse_expandable_bool { \__xparse_flush_m_args: }
+ }
+\cs_new_protected:Npn \__xparse_prepare_signature:N
+ {
+ \bool_set_false:N \l__xparse_prefixed_bool
+ \__xparse_prepare_signature_bypass:N
+ }
+\cs_new_protected:Npn \__xparse_prepare_signature_bypass:N #1
+ {
+ \quark_if_recursion_tail_stop:N #1
+ \use:c
+ {
+ __xparse_add
+ \bool_if:NT \l__xparse_grab_expandably_bool { _expandable }
+ _type_ \token_to_str:N #1 :w
+ }
+ }
+\cs_new_protected:cpn { __xparse_add_type_+:w }
+ {
+ \__xparse_flush_m_args:
+ \bool_set_true:N \l__xparse_long_bool
+ \bool_set_true:N \l__xparse_prefixed_bool
+ \__xparse_prepare_signature_bypass:N
+ }
+\cs_new_protected:cpn { __xparse_add_type_!:w }
+ {
+ \__xparse_flush_m_args:
+ \bool_set_true:N \l__xparse_obey_spaces_bool
+ \bool_set_true:N \l__xparse_prefixed_bool
+ \__xparse_prepare_signature_bypass:N
+ }
+\cs_new_protected:cpn { __xparse_add_type_>:w } #1
+ {
+ \__xparse_flush_m_args:
+ \bool_set_true:N \l__xparse_prefixed_bool
+ \bool_set_true:N \l__xparse_process_some_bool
+ \tl_put_left:Nn \l__xparse_process_one_tl { {#1} }
+ \__xparse_prepare_signature_bypass:N
+ }
+\cs_new_protected:Npn \__xparse_add_type_b:w
+ {
+ \__xparse_flush_m_args:
+ \__xparse_add_default:
+ \__xparse_add_grabber:N b
+ \__xparse_prepare_signature:N
+ }
+\cs_new_protected:Npn \__xparse_add_type_D:w #1#2#3
+ {
+ \__xparse_flush_m_args:
+ \__xparse_add_default:n {#3}
+ \__xparse_add_grabber:N D
+ \tl_put_right:Nn \l__xparse_signature_tl { #1 #2 }
+ \__xparse_prepare_signature:N
+ }
+\cs_new_protected:Npn \__xparse_add_type_E:w #1#2
+ {
+ \__xparse_flush_m_args:
+ \__xparse_add_default_E:nn {#1} {#2}
+ \__xparse_add_grabber:N E
+ \tl_put_right:Nn \l__xparse_signature_tl { {#1} }
+ \__xparse_prepare_signature:N
+ }
+\cs_new_protected:Npn \__xparse_add_type_m:w
+ {
+ \__xparse_add_default:
+ \bool_if:NTF \l__xparse_prefixed_bool
+ { \__xparse_add_grabber:N m }
+ { \int_incr:N \l__xparse_m_args_int }
+ \__xparse_prepare_signature:N
+ }
+\cs_new_protected:Npn \__xparse_add_type_R:w #1#2#3
+ {
+ \__xparse_flush_m_args:
+ \__xparse_add_default:n {#3}
+ \__xparse_add_grabber:N R
+ \tl_put_right:Nn \l__xparse_signature_tl { #1 #2 }
+ \__xparse_prepare_signature:N
+ }
+\cs_new_protected:Npn \__xparse_add_type_t:w #1
+ {
+ \__xparse_flush_m_args:
+ \__xparse_add_default:
+ \__xparse_add_grabber:N t
+ \tl_put_right:Nn \l__xparse_signature_tl {#1}
+ \__xparse_prepare_signature:N
+ }
+\cs_new_protected:Npn \__xparse_add_type_v:w
+ {
+ \__xparse_flush_m_args:
+ \exp_args:No \__xparse_add_default:n \c_novalue_tl
+ \__xparse_add_grabber:N v
+ \__xparse_prepare_signature:N
+ }
+\cs_new_protected:Npn \__xparse_flush_m_args:
+ {
+ \int_compare:nNnT \l__xparse_m_args_int > 0
+ {
+ \tl_put_right:Nx \l__xparse_signature_tl
+ { \exp_not:c { __xparse_grab_m_ \int_use:N \l__xparse_m_args_int :w } }
+ \tl_put_right:Nx \l__xparse_process_all_tl
+ { \prg_replicate:nn { \l__xparse_m_args_int } { { } } }
+ }
+ \int_zero:N \l__xparse_m_args_int
+ }
+\cs_new_protected:Npn \__xparse_add_grabber:N #1
+ {
+ \tl_put_right:Nx \l__xparse_signature_tl
+ {
+ \exp_not:c
+ {
+ __xparse_grab_ #1
+ \bool_if:NT \l__xparse_long_bool { _long }
+ \bool_if:NT \l__xparse_obey_spaces_bool { _obey_spaces }
+ :w
+ }
+ }
+ \bool_set_false:N \l__xparse_long_bool
+ \bool_set_false:N \l__xparse_obey_spaces_bool
+ \tl_put_right:Nx \l__xparse_process_all_tl
+ { { \exp_not:o \l__xparse_process_one_tl } }
+ \tl_clear:N \l__xparse_process_one_tl
+ }
+\cs_new_protected:Npn \__xparse_add_default:n #1
+ {
+ \tl_if_novalue:nTF {#1}
+ { \__xparse_add_default: }
+ {
+ \int_incr:N \l__xparse_current_arg_int
+ \bool_set_true:N \l__xparse_defaults_bool
+ \tl_put_right:Nn \l__xparse_defaults_tl { { \prg_do_nothing: #1 } }
+ }
+ }
+\cs_new_protected:Npn \__xparse_add_default:
+ {
+ \int_incr:N \l__xparse_current_arg_int
+ \tl_put_right:Nn \l__xparse_defaults_tl { \c_novalue_tl }
+ }
+\cs_new_protected:Npn \__xparse_add_default_E:nn #1#2
+ {
+ \tl_map_function:nN {#2} \__xparse_add_default:n
+ \prg_replicate:nn
+ { \tl_count:n {#1} - \tl_count:n {#2} }
+ { \__xparse_add_default: }
+ }
+\cs_new_protected:cpn { __xparse_add_expandable_type_+:w }
+ {
+ \bool_set_true:N \l__xparse_long_bool
+ \__xparse_prepare_signature:N
+ }
+\cs_new_protected:Npn \__xparse_add_expandable_type_D:w
+ { \__xparse_add_expandable_type_D_aux:NNNn D }
+\cs_new_protected:Npn \__xparse_add_expandable_type_D_aux:NNNn #1#2#3#4
+ {
+ \__xparse_add_default:n {#4}
+ \tl_if_eq:nnTF {#2} {#3}
+ { \__xparse_add_expandable_type_D_aux:NN #1 #2 }
+ { \__xparse_add_expandable_type_D_aux:NNN #1 #2 #3 }
+ \__xparse_prepare_signature:N
+ }
+\cs_new_protected:Npn \__xparse_add_expandable_type_D_aux:NNN #1#2#3
+ {
+ \bool_if:NTF \l__xparse_long_bool
+ { \cs_set:cpx }
+ { \cs_set_nopar:cpx }
+ { \l__xparse_expandable_aux_name_tl } ##1 ##2 #2 ##3 \q__xparse ##4 #3
+ { ##1 {##2} {##3} {##4} }
+ \__xparse_add_expandable_grabber:nn {#1}
+ {
+ \exp_not:c { \l__xparse_expandable_aux_name_tl }
+ \exp_not:n { #2 #3 }
+ }
+ }
+\cs_new_protected:Npn \__xparse_add_expandable_type_D_aux:NN #1#2
+ {
+ \bool_if:NTF \l__xparse_long_bool
+ { \cs_set:cpx }
+ { \cs_set_nopar:cpx }
+ { \l__xparse_expandable_aux_name_tl } ##1 #2 ##2 #2
+ { ##1 {##2} }
+ \__xparse_add_expandable_grabber:nn { #1_alt }
+ {
+ \exp_not:c { \l__xparse_expandable_aux_name_tl }
+ \exp_not:n {#2}
+ }
+ }
+\cs_new_protected:Npn \__xparse_add_expandable_type_E:w #1#2
+ {
+ \__xparse_add_default_E:nn {#1} {#2}
+ \tl_clear:N \l__xparse_tmpb_tl
+ \tl_map_function:nN {#1} \__xparse_add_expandable_type_E_aux:n
+ \__xparse_add_expandable_grabber:nn
+ { E \bool_if:NT \l__xparse_long_bool { _long } }
+ {
+ { \exp_not:o \l__xparse_tmpb_tl }
+ {
+ \prg_replicate:nn { \tl_count:n {#1} }
+ { { \c_novalue_tl } }
+ }
+ }
+ \__xparse_prepare_signature:N
+ }
+\cs_new_protected:Npn \__xparse_add_expandable_type_E_aux:n #1
+ {
+ \__xparse_get_grabber:NN #1 \l__xparse_tmpa_tl
+ \tl_put_right:Nx \l__xparse_tmpb_tl
+ { \exp_not:o \l__xparse_tmpa_tl \exp_not:N #1 }
+ }
+\cs_new_protected:Npn \__xparse_add_expandable_type_m:w
+ {
+ \__xparse_add_default:
+ \__xparse_add_expandable_grabber:nn
+ { m \bool_if:NT \l__xparse_long_bool { _long } } { }
+ \__xparse_prepare_signature:N
+ }
+\cs_new_protected:Npn \__xparse_add_expandable_type_R:w
+ { \__xparse_add_expandable_type_D_aux:NNNn R }
+\cs_new_protected:Npn \__xparse_add_expandable_type_t:w #1
+ {
+ \__xparse_add_default:
+ \__xparse_get_grabber:NN #1 \l__xparse_tmpa_tl
+ \__xparse_add_expandable_grabber:nn { t }
+ {
+ \exp_not:o \l__xparse_tmpa_tl
+ \exp_not:N #1
+ }
+ \__xparse_prepare_signature:N
+ }
+\cs_new_protected:Npn \__xparse_add_expandable_grabber:nn #1#2
+ {
+ \tl_put_right:Nx \l__xparse_signature_tl
+ { \exp_not:c { __xparse_expandable_grab_ #1 :w } #2 }
+ }
+\cs_new_protected:Npn \__xparse_get_grabber:NN #1#2
+ {
+ \cs_set:Npn \__xparse_tmp:w ##1 #1 {##1}
+ \exp_args:Nc \__xparse_get_grabber_auxi:NN
+ { __xparse_grabber_ \token_to_str:N #1 :w } #2
+ }
+\cs_new_protected:Npn \__xparse_get_grabber_auxi:NN #1#2
+ {
+ \cs_if_eq:NNTF \__xparse_tmp:w #1
+ { \tl_set:Nn #2 {#1} }
+ {
+ \cs_if_exist:NTF #1
+ {
+ \int_gincr:N \g__xparse_grabber_int
+ \exp_args:Nc \__xparse_get_grabber_auxi:NN
+ {
+ __xparse_grabber_
+ - \int_use:N \g__xparse_grabber_int :w
+ }
+ #2
+ }
+ { \__xparse_get_grabber_auxii:NN #1 #2 }
+ }
+ }
+\cs_new_protected:Npn \__xparse_get_grabber_auxii:NN #1#2
+ {
+ \cs_set_eq:NN #1 \__xparse_tmp:w
+ \tl_set:Nn #2 {#1}
+ }
+\cs_new_protected:Npn \__xparse_grab_b:w
+ { \__xparse_grab_b_aux:NNw \cs_set_protected_nopar:Npn \tl_trim_spaces:n }
+\cs_new_protected:Npn \__xparse_grab_b_long:w
+ { \__xparse_grab_b_aux:NNw \cs_set_protected:Npn \tl_trim_spaces:n }
+\cs_new_protected:Npn \__xparse_grab_b_obey_spaces:w
+ { \__xparse_grab_b_aux:NNw \cs_set_protected_nopar:Npn \exp_not:n }
+\cs_new_protected:Npn \__xparse_grab_b_long_obey_spaces:w
+ { \__xparse_grab_b_aux:NNw \cs_set_protected:Npn \exp_not:n }
+\cs_new_protected:Npn \__xparse_grab_b_aux:NNw #1#2#3 \__xparse_run_code:
+ {
+ \__xparse_grab_D_aux:NNnN \begin \end {#3} #1
+ \tl_put_left:Nn \l__xparse_signature_tl { \__xparse_grab_b_end:Nw #2 }
+ \tl_set_eq:NN \l__xparse_saved_args_tl \l__xparse_args_tl
+ \tl_clear:N \l__xparse_args_tl
+ \exp_args:Nc \l__xparse_fn_tl { begin ~ }
+ }
+\cs_new_protected:Npn \__xparse_grab_b_end:Nw #1#2 \__xparse_run_code:
+ {
+ \tl_set:Nx \l__xparse_args_tl
+ {
+ \exp_not:V \l__xparse_saved_args_tl
+ { \exp_after:wN #1 \l__xparse_args_tl }
+ }
+ #2
+ \__xparse_run_code:
+ \end
+ }
+\cs_new_protected:Npn \__xparse_grab_D:w #1#2#3 \__xparse_run_code:
+ {
+ \__xparse_grab_D_aux:NNnNN #1 #2 {#3} \cs_set_protected_nopar:Npn
+ \__xparse_peek_nonspace_remove:NTF
+ }
+\cs_new_protected:Npn \__xparse_grab_D_long:w #1#2#3 \__xparse_run_code:
+ {
+ \__xparse_grab_D_aux:NNnNN #1 #2 {#3} \cs_set_protected:Npn
+ \__xparse_peek_nonspace_remove:NTF
+ }
+\cs_new_protected:Npn \__xparse_grab_D_obey_spaces:w #1#2#3 \__xparse_run_code:
+ {
+ \__xparse_grab_D_aux:NNnNN #1 #2 {#3} \cs_set_protected_nopar:Npn
+ \__xparse_peek_meaning_remove:NTF
+ }
+\cs_new_protected:Npn \__xparse_grab_D_long_obey_spaces:w #1#2#3 \__xparse_run_code:
+ {
+ \__xparse_grab_D_aux:NNnNN #1 #2 {#3} \cs_set_protected:Npn
+ \__xparse_peek_meaning_remove:NTF
+ }
+\cs_new_protected:Npn \__xparse_grab_D_aux:NNnNN #1#2#3#4#5
+ {
+ \__xparse_grab_D_aux:NNnN #1#2 {#3} #4
+ #5 #1
+ { \__xparse_grab_D_call:Nw #1 }
+ { \__xparse_add_arg:o \c_novalue_tl }
+ }
+\cs_new_protected:Npn \__xparse_grab_D_aux:NNnN #1#2#3#4
+ {
+ \tl_set:Nn \l__xparse_signature_tl {#3}
+ \exp_after:wN #4 \l__xparse_fn_tl ##1 #2
+ {
+ \tl_if_in:nnTF {##1} {#1}
+ { \__xparse_grab_D_nested:NNnN #1 #2 {##1} #4 }
+ {
+ \tl_if_blank:oTF { \use_none:n ##1 }
+ { \__xparse_add_arg:o { \use_none:n ##1 } }
+ {
+ \str_if_eq:eeTF
+ { \exp_not:o { \use_none:n ##1 } }
+ { { \exp_not:o { \use_ii:nnn ##1 \q_nil } } }
+ { \__xparse_add_arg:o { \use_ii:nn ##1 } }
+ { \__xparse_add_arg:o { \use_none:n ##1 } }
+ }
+ }
+ }
+ }
+\tl_new:N \l__xparse_nesting_a_tl
+\tl_new:N \l__xparse_nesting_b_tl
+\quark_new:N \q__xparse
+\cs_new_protected:Npn \__xparse_grab_D_nested:NNnN #1#2#3#4
+ {
+ \tl_clear:N \l__xparse_nesting_a_tl
+ \tl_clear:N \l__xparse_nesting_b_tl
+ \exp_after:wN #4 \l__xparse_fn_tl ##1 #1 ##2 \q__xparse ##3 #2
+ {
+ \tl_put_right:No \l__xparse_nesting_a_tl { \use_none:n ##1 #1 }
+ \tl_put_right:No \l__xparse_nesting_b_tl { \use_i:nn #2 ##3 }
+ \tl_if_in:nnTF {##2} {#1}
+ {
+ \l__xparse_fn_tl
+ \q_nil ##2 \q__xparse \ERROR
+ }
+ {
+ \tl_put_right:Nx \l__xparse_nesting_a_tl
+ { \__xparse_grab_D_nested:w \q_nil ##2 \q_stop }
+ \tl_if_in:NnTF \l__xparse_nesting_b_tl {#1}
+ {
+ \tl_set_eq:NN \l__xparse_tmpa_tl \l__xparse_nesting_b_tl
+ \tl_clear:N \l__xparse_nesting_b_tl
+ \exp_after:wN \l__xparse_fn_tl \exp_after:wN
+ \q_nil \l__xparse_tmpa_tl \q_nil \q__xparse \ERROR
+ }
+ {
+ \tl_put_right:No \l__xparse_nesting_a_tl
+ \l__xparse_nesting_b_tl
+ \__xparse_add_arg:V \l__xparse_nesting_a_tl
+ }
+ }
+ }
+ \l__xparse_fn_tl #3 \q_nil \q__xparse \ERROR
+ }
+\cs_new:Npn \__xparse_grab_D_nested:w #1 \q_nil \q_stop
+ { \exp_not:o { \use_none:n #1 } }
+\cs_new_protected_nopar:Npn \__xparse_grab_D_call:Nw #1
+ {
+ \token_if_eq_catcode:NNTF + #1
+ {
+ \exp_after:wN \exp_after:wN \exp_after:wN
+ \l__xparse_fn_tl \char_generate:nn { `#1 } { 11 }
+ }
+ {
+ \__xparse_token_if_cs:NTF #1
+ {
+ \exp_after:wN \l__xparse_fn_tl
+ \cs:w \cs_to_str:N #1 ~ \cs_end:
+ }
+ {
+ \exp_after:wN \l__xparse_fn_tl
+ \token_to_str:N #1
+ }
+ }
+ }
+\cs_new_protected:Npn \__xparse_grab_E:w #1#2 \__xparse_run_code:
+ {
+ \__xparse_grab_E:nnNN {#1} {#2}
+ \cs_set_protected_nopar:Npn
+ \__xparse_peek_nonspace_remove:NTF
+ }
+\cs_new_protected:Npn \__xparse_grab_E_long:w #1#2 \__xparse_run_code:
+ {
+ \__xparse_grab_E:nnNN {#1} {#2}
+ \cs_set_protected:Npn
+ \__xparse_peek_nonspace_remove:NTF
+ }
+\cs_new_protected:Npn \__xparse_grab_E_obey_spaces:w #1#2 \__xparse_run_code:
+ {
+ \__xparse_grab_E:nnNN {#1} {#2}
+ \cs_set_protected_nopar:Npn
+ \__xparse_peek_meaning_remove:NTF
+ }
+\cs_new_protected:Npn \__xparse_grab_E_long_obey_spaces:w #1#2 \__xparse_run_code:
+ {
+ \__xparse_grab_E:nnNN {#1} {#2}
+ \cs_set_protected:Npn
+ \__xparse_peek_meaning_remove:NTF
+ }
+\cs_new_protected:Npn \__xparse_grab_E:nnNN #1#2#3#4
+ {
+ \exp_after:wN #3 \l__xparse_fn_tl ##1##2##3
+ {
+ \prop_put:Nnn \l__xparse_tmp_prop {##1} {##3}
+ \__xparse_grab_E_loop:NnN #4 { } ##2 \q_recursion_stop
+ }
+ \prop_clear:N \l__xparse_tmp_prop
+ \tl_set:Nn \l__xparse_signature_tl {#2}
+ \cs_set_protected:Npn \__xparse_grab_E_finalise:
+ {
+ \tl_map_inline:nn {#1}
+ {
+ \prop_get:NnNF \l__xparse_tmp_prop {####1} \l__xparse_tmpb_tl
+ { \tl_set_eq:NN \l__xparse_tmpb_tl \c_novalue_tl }
+ \tl_put_right:Nx \l__xparse_args_tl
+ { { \exp_not:V \l__xparse_tmpb_tl } }
+ }
+ \l__xparse_signature_tl \__xparse_run_code:
+ }
+ \__xparse_grab_E_loop:NnN #4 { } #1 \q_recursion_tail \q_recursion_stop
+ }
+\cs_new_protected:Npn \__xparse_grab_E_loop:NnN #1#2#3#4 \q_recursion_stop
+ {
+ \cs_if_eq:NNTF #3 \q_recursion_tail
+ { \__xparse_grab_E_finalise: }
+ {
+ #1 #3
+ { \l__xparse_fn_tl #3 {#2#4} }
+ { \__xparse_grab_E_loop:NnN #1 {#2#3} #4 \q_recursion_stop }
+ }
+ }
+\cs_new_protected:Npn \__xparse_grab_E_finalise: { }
+\cs_new_protected:Npn \__xparse_grab_m:w #1 \__xparse_run_code:
+ {
+ \tl_set:Nn \l__xparse_signature_tl {#1}
+ \exp_after:wN \cs_set_protected_nopar:Npn \l__xparse_fn_tl ##1
+ { \__xparse_add_arg:n {##1} }
+ \l__xparse_fn_tl
+ }
+\cs_new_protected:Npn \__xparse_grab_m_long:w #1 \__xparse_run_code:
+ {
+ \tl_set:Nn \l__xparse_signature_tl {#1}
+ \exp_after:wN \cs_set_protected:Npn \l__xparse_fn_tl ##1
+ { \__xparse_add_arg:n {##1} }
+ \l__xparse_fn_tl
+ }
+\cs_new_protected_nopar:Npn \__xparse_grab_m_aux:Nnnnnnnnn #1#2#3#4#5#6#7#8#9
+ {
+ \tl_put_right:No \l__xparse_args_tl
+ { #1 {#2} {#3} {#4} {#5} {#6} {#7} {#8} {#9} }
+ \l__xparse_signature_tl \__xparse_run_code:
+ }
+\cs_new_protected:cpn { __xparse_grab_m_1:w } #1 \__xparse_run_code:
+ {
+ \tl_set:Nn \l__xparse_signature_tl {#1}
+ \exp_after:wN \cs_set_eq:NN \l__xparse_fn_tl \__xparse_grab_m_aux:Nnnnnnnnn
+ \l__xparse_fn_tl \use_none:nnnnnnn { } { } { } { } { } { } { }
+ }
+\cs_new_protected:cpn { __xparse_grab_m_2:w } #1 \__xparse_run_code:
+ {
+ \tl_set:Nn \l__xparse_signature_tl {#1}
+ \exp_after:wN \cs_set_eq:NN \l__xparse_fn_tl \__xparse_grab_m_aux:Nnnnnnnnn
+ \l__xparse_fn_tl \use_none:nnnnnn { } { } { } { } { } { }
+ }
+\cs_new_protected:cpn { __xparse_grab_m_3:w } #1 \__xparse_run_code:
+ {
+ \tl_set:Nn \l__xparse_signature_tl {#1}
+ \exp_after:wN \cs_set_eq:NN \l__xparse_fn_tl \__xparse_grab_m_aux:Nnnnnnnnn
+ \l__xparse_fn_tl \use_none:nnnnn { } { } { } { } { }
+ }
+\cs_new_protected:cpn { __xparse_grab_m_4:w } #1 \__xparse_run_code:
+ {
+ \tl_set:Nn \l__xparse_signature_tl {#1}
+ \exp_after:wN \cs_set_eq:NN \l__xparse_fn_tl \__xparse_grab_m_aux:Nnnnnnnnn
+ \l__xparse_fn_tl \use_none:nnnn { } { } { } { }
+ }
+\cs_new_protected:cpn { __xparse_grab_m_5:w } #1 \__xparse_run_code:
+ {
+ \tl_set:Nn \l__xparse_signature_tl {#1}
+ \exp_after:wN \cs_set_eq:NN \l__xparse_fn_tl \__xparse_grab_m_aux:Nnnnnnnnn
+ \l__xparse_fn_tl \use_none:nnn { } { } { }
+ }
+\cs_new_protected:cpn { __xparse_grab_m_6:w } #1 \__xparse_run_code:
+ {
+ \tl_set:Nn \l__xparse_signature_tl {#1}
+ \exp_after:wN \cs_set_eq:NN \l__xparse_fn_tl \__xparse_grab_m_aux:Nnnnnnnnn
+ \l__xparse_fn_tl \use_none:nn { } { }
+ }
+\cs_new_protected:cpn { __xparse_grab_m_7:w } #1 \__xparse_run_code:
+ {
+ \tl_set:Nn \l__xparse_signature_tl {#1}
+ \exp_after:wN \cs_set_eq:NN \l__xparse_fn_tl \__xparse_grab_m_aux:Nnnnnnnnn
+ \l__xparse_fn_tl \use_none:n { }
+ }
+\cs_new_protected:cpn { __xparse_grab_m_8:w } #1 \__xparse_run_code:
+ {
+ \tl_set:Nn \l__xparse_signature_tl {#1}
+ \exp_after:wN \cs_set_eq:NN \l__xparse_fn_tl \__xparse_grab_m_aux:Nnnnnnnnn
+ \l__xparse_fn_tl \prg_do_nothing:
+ }
+\cs_new_protected:cpx { __xparse_grab_m_9:w }
+ {
+ \exp_not:c { __xparse_grab_m_5:w }
+ \exp_not:c { __xparse_grab_m_4:w }
+ }
+\cs_new_protected:Npn \__xparse_grab_R:w #1#2#3 \__xparse_run_code:
+ { \__xparse_grab_R_aux:NNnN #1 #2 {#3} \cs_set_protected_nopar:Npn }
+\cs_new_protected:Npn \__xparse_grab_R_long:w #1#2#3 \__xparse_run_code:
+ { \__xparse_grab_R_aux:NNnN #1 #2 {#3} \cs_set_protected:Npn }
+\cs_new_protected:Npn \__xparse_grab_R_aux:NNnN #1#2#3#4
+ {
+ \__xparse_grab_D_aux:NNnN #1 #2 {#3} #4
+ \__xparse_peek_nonspace_remove:NTF #1
+ { \__xparse_grab_D_call:Nw #1 }
+ {
+ \__kernel_msg_error:nnxx { xparse } { missing-required }
+ { \__xparse_environment_or_command: }
+ { \token_to_str:N #1 }
+ \__xparse_add_arg:o \c_novalue_tl
+ }
+ }
+\cs_new_protected:Npn \__xparse_grab_t:w
+ { \__xparse_grab_t_aux:NNw \__xparse_peek_nonspace_remove:NTF }
+\cs_new_protected:Npn \__xparse_grab_t_obey_spaces:w
+ { \__xparse_grab_t_aux:NNw \__xparse_peek_meaning_remove:NTF }
+\cs_new_protected:Npn \__xparse_grab_t_aux:NNw #1#2#3 \__xparse_run_code:
+ {
+ \tl_set:Nn \l__xparse_signature_tl {#3}
+ \exp_after:wN \cs_set_protected:Npn \l__xparse_fn_tl
+ {
+ #1 #2
+ { \__xparse_add_arg:n { \BooleanTrue } }
+ { \__xparse_add_arg:n { \BooleanFalse } }
+ }
+ \l__xparse_fn_tl
+ }
+\tl_new:N \l__xparse_v_arg_tl
+\cs_new_protected:Npn \__xparse_grab_v:w
+ {
+ \bool_set_false:N \l__xparse_long_bool
+ \__xparse_grab_v_aux:w
+ }
+\cs_new_protected:Npn \__xparse_grab_v_long:w
+ {
+ \bool_set_true:N \l__xparse_long_bool
+ \__xparse_grab_v_aux:w
+ }
+\cs_new_protected:Npn \__xparse_grab_v_aux:w #1 \__xparse_run_code:
+ {
+ \tl_set:Nn \l__xparse_signature_tl {#1}
+ \group_begin:
+ \group_align_safe_begin:
+ \tex_escapechar:D = 92 \scan_stop:
+ \tl_clear:N \l__xparse_v_arg_tl
+ \peek_remove_spaces:n
+ {
+ \peek_meaning_remove:NTF \c_group_begin_token
+ {
+ \group_align_safe_end:
+ \__xparse_grab_v_bgroup:
+ }
+ {
+ \peek_N_type:TF
+ { \__xparse_grab_v_aux_test:N }
+ { \__xparse_grab_v_aux_abort:n { } }
+ }
+ }
+ }
+\cs_new_protected:Npn \__xparse_grab_v_group_end:
+ {
+ \group_align_safe_end:
+ \exp_args:NNNo
+ \group_end:
+ \tl_set:Nn \l__xparse_v_arg_tl { \l__xparse_v_arg_tl }
+ }
+\cs_new_protected:Npn \__xparse_grab_v_aux_test:N #1
+ {
+ \__xparse_grab_v_token_if_char:NTF #1
+ {
+ \__xparse_grab_v_aux_put:N #1
+ \__xparse_grab_v_aux_catcodes:
+ \__xparse_grab_v_aux_loop:N #1
+ }
+ { \__xparse_grab_v_aux_abort:n {#1} #1 }
+ }
+\cs_new_protected:Npn \__xparse_grab_v_aux_loop:N #1
+ {
+ \peek_N_type:TF
+ { \__xparse_grab_v_aux_loop:NN #1 }
+ { \__xparse_grab_v_aux_abort:n { } }
+ }
+\cs_new_protected:Npn \__xparse_grab_v_aux_loop:NN #1#2
+ {
+ \__xparse_grab_v_token_if_char:NTF #2
+ {
+ \token_if_eq_charcode:NNTF #1 #2
+ { \__xparse_grab_v_aux_loop_end: }
+ {
+ \__xparse_grab_v_aux_put:N #2
+ \__xparse_grab_v_aux_loop:N #1
+ }
+ }
+ { \__xparse_grab_v_aux_abort:n {#2} #2 }
+ }
+\cs_new_protected:Npn \__xparse_grab_v_aux_loop_end:
+ {
+ \__xparse_grab_v_group_end:
+ \__xparse_add_arg:x { \tl_tail:N \l__xparse_v_arg_tl }
+ }
+\int_new:N \l__xparse_v_nesting_int
+\cs_new_protected:Npx \__xparse_grab_v_bgroup:
+ {
+ \exp_not:N \__xparse_grab_v_aux_catcodes:
+ \exp_not:n { \int_set:Nn \l__xparse_v_nesting_int { 1 } }
+ \exp_not:N \__xparse_grab_v_aux_put:N \iow_char:N \{
+ \exp_not:N \__xparse_grab_v_bgroup_loop:
+ }
+\cs_new_protected:Npn \__xparse_grab_v_bgroup_loop:
+ {
+ \peek_N_type:TF
+ { \__xparse_grab_v_bgroup_loop:N }
+ { \__xparse_grab_v_aux_abort:n { } }
+ }
+\cs_new_protected:Npn \__xparse_grab_v_bgroup_loop:N #1
+ {
+ \__xparse_grab_v_token_if_char:NTF #1
+ {
+ \token_if_eq_charcode:NNTF \c_group_end_token #1
+ {
+ \int_decr:N \l__xparse_v_nesting_int
+ \int_compare:nNnTF \l__xparse_v_nesting_int > 0
+ {
+ \__xparse_grab_v_aux_put:N #1
+ \__xparse_grab_v_bgroup_loop:
+ }
+ { \__xparse_grab_v_aux_loop_end: }
+ }
+ {
+ \token_if_eq_charcode:NNT \c_group_begin_token #1
+ { \int_incr:N \l__xparse_v_nesting_int }
+ \__xparse_grab_v_aux_put:N #1
+ \__xparse_grab_v_bgroup_loop:
+ }
+ }
+ { \__xparse_grab_v_aux_abort:n {#1} #1 }
+ }
+\cs_new_protected:Npn \__xparse_grab_v_aux_catcodes:
+ {
+ \cs_set_eq:NN \do \char_set_catcode_other:N
+ \dospecials
+ \tex_endlinechar:D = `\^^M \scan_stop:
+ \bool_if:NTF \l__xparse_long_bool
+ { \char_set_catcode_other:n { \tex_endlinechar:D } }
+ { \char_set_catcode_parameter:n { \tex_endlinechar:D } }
+ }
+\cs_new_protected:Npn \__xparse_grab_v_aux_abort:n #1
+ {
+ \__xparse_grab_v_group_end:
+ \exp_after:wN \exp_after:wN \exp_after:wN
+ \peek_meaning_remove:NTF \char_generate:nn { \tex_endlinechar:D } { 6 }
+ {
+ \__kernel_msg_error:nnxxx { xparse } { verbatim-newline }
+ { \__xparse_environment_or_command: }
+ { \tl_to_str:N \l__xparse_v_arg_tl }
+ { \tl_to_str:n {#1} }
+ \__xparse_add_arg:o \c_novalue_tl
+ }
+ {
+ \__kernel_msg_error:nnxxx { xparse } { verbatim-tokenized }
+ { \__xparse_environment_or_command: }
+ { \tl_to_str:N \l__xparse_v_arg_tl }
+ { \tl_to_str:n {#1} }
+ \__xparse_add_arg:o \c_novalue_tl
+ }
+ }
+\cs_new_protected:Npn \__xparse_grab_v_aux_put:N #1
+ {
+ \tl_put_right:Nx \l__xparse_v_arg_tl
+ {
+ \token_if_active:NTF #1
+ { \exp_not:N #1 } { \token_to_str:N #1 }
+ }
+ }
+\cs_new_protected:Npn \__xparse_grab_v_token_if_char:NTF #1
+ { \str_if_eq:eeTF { } { \str_tail:n {#1} } }
+\cs_new_protected:Npn \__xparse_add_arg:n #1
+ {
+ \tl_put_right:Nn \l__xparse_args_tl { {#1} }
+ \l__xparse_signature_tl \__xparse_run_code:
+ }
+\cs_generate_variant:Nn \__xparse_add_arg:n { V , o , x }
+\cs_new:Npn \__xparse_expandable_grab_D:w #1 \q__xparse #2#3
+ { #2 { \__xparse_expandable_grab_D:NNNwNNn #1 \q__xparse #2 #3 } }
+\cs_set_protected:Npn \__xparse_tmp:w #1
+ {
+ \cs_new:Npn \__xparse_expandable_grab_D:NNNwNNn ##1##2##3##4 \q__xparse ##5##6##7
+ {
+ \str_if_eq:nnTF {##2} {##7}
+ {
+ \str_if_eq:onTF
+ { ##1 { } { } ##7 ##2 \q__xparse ##3 }
+ { { } {##2} { } }
+ }
+ { \use_ii:nn }
+ {
+ ##1
+ { \__xparse_expandable_grab_D:NNNwNNnnn ##1##2##3##4 \q__xparse ##5##6 }
+ \q_nil { } ##2 \ERROR \q__xparse \ERROR
+ }
+ { ##4 {#1} \q__xparse ##5 ##6 {##7} }
+ }
+ }
+\exp_args:No \__xparse_tmp:w { \c_novalue_tl }
+\cs_new:Npn \__xparse_expandable_grab_D:NNNwNNnnn #1#2#3#4 \q__xparse #5#6#7#8#9
+ {
+ \exp_args:Nof \__xparse_expandable_grab_D:nnNNNwNN
+ { \use_ii:nn #7 #2 }
+ { \__xparse_expandable_grab_D:Nw #3 \exp_stop_f: #8 #9 }
+ #1#2#3 #4 \q__xparse #5 #6
+ }
+\cs_new:Npn \__xparse_expandable_grab_D:Nw #1#2 \ERROR \ERROR { #2 #1 }
+\cs_new:Npn \__xparse_expandable_grab_D:nnNNNwNN #1#2#3#4#5#6 \q__xparse #7#8
+ {
+ \exp_args:No \tl_if_empty:oTF
+ { #3 { \use_none:nnn } #2 \q__xparse #5 #4 \q__xparse #5 }
+ {
+ \tl_if_blank:oTF { \use_none:nn #1#2 }
+ { \__xparse_put_arg_expandable:ow { \use_none:nn #1#2 } }
+ {
+ \str_if_eq:eeTF
+ { \exp_not:o { \use_none:nn #1#2 } }
+ { { \exp_not:o { \use_iii:nnnn #1#2 \q_nil } } }
+ { \__xparse_put_arg_expandable:ow { \use_iii:nnn #1#2 } }
+ { \__xparse_put_arg_expandable:ow { \use_none:nn #1#2 } }
+ }
+ #6 \q__xparse #7 #8
+ }
+ {
+ #3
+ { \__xparse_expandable_grab_D:NNNwNNnnn #3#4#5#6 \q__xparse #7 #8 }
+ \q_nil {#1} #2 \ERROR \q__xparse \ERROR
+ }
+ }
+\cs_new:Npn \__xparse_expandable_grab_D_alt:w #1 \q__xparse #2#3
+ { #2 { \__xparse_expandable_grab_D_alt:NNwNNn #1 \q__xparse #2 #3 } }
+\cs_set_protected:Npn \__xparse_tmp:w #1
+ {
+ \cs_new:Npn \__xparse_expandable_grab_D_alt:NNwNNn ##1##2##3 \q__xparse ##4##5##6
+ {
+ \str_if_eq:nnTF {##6} {##2}
+ {
+ \str_if_eq:onTF
+ { ##1 { } ##6 ##2 ##2 }
+ { { } ##2 }
+ }
+ { \use_ii:nn }
+ {
+ ##1
+ { \__xparse_expandable_grab_D_alt:NNwn ##4 ##5 ##3 \q__xparse }
+ ##6 \ERROR
+ }
+ { ##3 {#1} \q__xparse ##4 ##5 {##6} }
+ }
+ }
+\exp_args:No \__xparse_tmp:w { \c_novalue_tl }
+\cs_new:Npn \__xparse_expandable_grab_D_alt:NNwn #1#2#3 \q__xparse #4
+ {
+ \tl_if_blank:oTF { \use_none:n #4 }
+ { \__xparse_put_arg_expandable:ow { \use_none:n #4 } }
+ {
+ \str_if_eq:eeTF
+ { \exp_not:o { \use_none:n #4 } }
+ { { \exp_not:o { \use_ii:nnn #4 \q_nil } } }
+ { \__xparse_put_arg_expandable:ow { \use_ii:nn #4 } }
+ { \__xparse_put_arg_expandable:ow { \use_none:n #4 } }
+ }
+ #3 \q__xparse #1 #2
+ }
+\cs_new:Npn \__xparse_expandable_grab_E:w #1 \q__xparse #2#3
+ { \__xparse_expandable_grab_E_aux:w #1 \q__xparse #2 #3 #3 }
+\cs_new:Npn \__xparse_expandable_grab_E_long:w #1 \q__xparse #2#3
+ { \__xparse_expandable_grab_E_aux:w #1 \q__xparse #2 #3 #2 }
+\cs_new:Npn \__xparse_expandable_grab_E_aux:w #1 \q__xparse #2#3#4
+ { #2 { \__xparse_expandable_grab_E_test:nnw #1 \q__xparse #2 #3 #4 } }
+\cs_new:Npn \__xparse_expandable_grab_E_test:nnw #1#2#3 \q__xparse #4#5#6#7
+ {
+ \__xparse_expandable_grab_E_loop:nnnNNw {#7} { } { }
+ #1 \q_nil \q_nil \q_nil \q_mark #2 \q_nil
+ #3 \q__xparse #4 #5 #6
+ }
+\cs_new:Npn \__xparse_expandable_grab_E_loop:nnnNNw
+ #1#2#3#4#5#6 \q_nil #7 \q_mark #8
+ {
+ \quark_if_nil:NTF #4
+ { \__xparse_expandable_grab_E_end:nnw {#1} {#3} }
+ {
+ \tl_if_novalue:nTF {#8}
+ { \str_if_eq:onTF { #4 { } #1 #5 } {#5} }
+ { \use_ii:nn }
+ { \__xparse_expandable_grab_E_find:w { #2 #4 #5 #6 } {#3} ~ }
+ {
+ \__xparse_expandable_grab_E_loop:nnnNNw
+ {#1} { #2 #4 #5 } { #3 {#8} }
+ #6 \q_nil #7 \q_mark
+ }
+ }
+ }
+\cs_new:Npn \__xparse_expandable_grab_E_find:w #1 \q__xparse #2#3#4
+ { #4 { \__xparse_expandable_grab_E_find:nnw #1 \q__xparse #2 #3 #4 } }
+\cs_new:Npn \__xparse_expandable_grab_E_find:nnw #1#2#3 \q_nil #4 \q__xparse #5#6#7#8
+ { \__xparse_expandable_grab_E_aux:w {#1} { #2 {#8} #3 } #4 \q__xparse #5 #6 #7 }
+\cs_new:Npn \__xparse_expandable_grab_E_end:nnw #1#2#3 \q__xparse #4#5#6
+ { #3 #2 \q__xparse #4 #5 {#1} }
+\cs_new:Npn \__xparse_expandable_grab_m:w #1 \q__xparse #2#3
+ { #3 { \__xparse_expandable_grab_m_aux:wNn #1 \q__xparse #2 #3 } }
+\cs_new:Npn \__xparse_expandable_grab_m_long:w #1 \q__xparse #2#3
+ { #2 { \__xparse_expandable_grab_m_aux:wNn #1 \q__xparse #2 #3 } }
+\cs_new:Npn \__xparse_expandable_grab_m_aux:wNn #1 \q__xparse #2#3#4
+ { #1 {#4} \q__xparse #2 #3 }
+\cs_new:Npn \__xparse_expandable_grab_R:w #1 \q__xparse #2#3
+ { #2 { \__xparse_expandable_grab_R_aux:NNNwNNn #1 \q__xparse #2#3 } }
+\cs_set_protected:Npn \__xparse_tmp:w #1
+ {
+ \cs_new:Npn \__xparse_expandable_grab_R_aux:NNNwNNn ##1##2##3##4 \q__xparse ##5##6##7
+ {
+ \str_if_eq:nnTF {##7} {##2}
+ {
+ \str_if_eq:onTF
+ { ##1 { } { } ##7 ##2 \q__xparse ##3 }
+ { { } {##2} { } }
+ }
+ { \use_ii:nn }
+ {
+ ##1
+ { \__xparse_expandable_grab_D:NNNwNNnnn ##1##2##3##4 \q__xparse ##5##6 }
+ \q_nil { } ##2 \ERROR \q__xparse \ERROR
+ }
+ {
+ \__kernel_msg_expandable_error:nnff
+ { xparse } { missing-required }
+ { \exp_args:Nf \tl_trim_spaces:n { \token_to_str:N ##5 } }
+ { \tl_to_str:n {##2} }
+ ##4 {#1} \q__xparse ##5 ##6 {##7}
+ }
+ }
+ }
+\exp_args:No \__xparse_tmp:w { \c_novalue_tl }
+\cs_new:Npn \__xparse_expandable_grab_R_alt:w #1 \q__xparse #2#3
+ { #2 { \__xparse_expandable_grab_R_alt_aux:NNwNNn #1 \q__xparse #2#3 } }
+\cs_set_protected:Npn \__xparse_tmp:w #1
+ {
+ \cs_new:Npn \__xparse_expandable_grab_R_alt_aux:NNwNNn ##1##2##3 \q__xparse ##4##5##6
+ {
+ \str_if_eq:nnTF {##6} {##2}
+ {
+ \str_if_eq:onTF
+ { ##1 { } ##6 ##2 ##2 }
+ { { } ##2 }
+ }
+ { \use_ii:nn }
+ {
+ ##1
+ { \__xparse_expandable_grab_D_alt:NNwn ##4 ##5 ##3 \q__xparse }
+ ##6 \ERROR
+ }
+ {
+ \__kernel_msg_expandable_error:nnff
+ { xparse } { missing-required }
+ { \exp_args:Nf \tl_trim_spaces:n { \token_to_str:N ##4 } }
+ { \tl_to_str:n {##2} }
+ ##3 {#1} \q__xparse ##4 ##5 {##6}
+ }
+ }
+ }
+\exp_args:No \__xparse_tmp:w { \c_novalue_tl }
+\cs_new:Npn \__xparse_expandable_grab_t:w #1 \q__xparse #2#3
+ { #2 { \__xparse_expandable_grab_t_aux:NNwn #1 \q__xparse #2 #3 } }
+\cs_new:Npn \__xparse_expandable_grab_t_aux:NNwn #1#2#3 \q__xparse #4#5#6
+ {
+ \str_if_eq:onTF { #1 { } #6 #2 } {#2}
+ { #3 { \BooleanTrue } \q__xparse #4 #5 }
+ { #3 { \BooleanFalse } \q__xparse #4 #5 {#6} }
+ }
+\cs_new_eq:NN \__xparse_expandable_grab_u:w \prg_do_nothing:
+\cs_new:Npn \__xparse_put_arg_expandable:nw #1#2 \q__xparse { #2 {#1} \q__xparse }
+\cs_generate_variant:Nn \__xparse_put_arg_expandable:nw { o }
+\cs_new_protected:Npn \__xparse_bool_reverse:N #1
+ {
+ \bool_if:NTF #1
+ { \tl_set:Nn \ProcessedArgument { \c_false_bool } }
+ { \tl_set:Nn \ProcessedArgument { \c_true_bool } }
+ }
+\seq_new:N \l__xparse_split_list_seq
+\tl_new:N \l__xparse_split_list_tl
+\cs_new_protected:Npn \__xparse_split_list:nn #1#2
+ {
+ \tl_if_single:nTF {#1}
+ {
+ \token_if_cs:NTF #1
+ { \__xparse_split_list_multi:nn {#1} {#2} }
+ { \__xparse_split_list_single:Nn #1 {#2} }
+ }
+ { \__xparse_split_list_multi:nn {#1} {#2} }
+ }
+\cs_new_protected:Npn \__xparse_split_list_multi:nn #1#2
+ {
+ \seq_set_split:Nnn \l__xparse_split_list_seq {#1} {#2}
+ \tl_clear:N \ProcessedArgument
+ \seq_map_inline:Nn \l__xparse_split_list_seq
+ { \tl_put_right:Nn \ProcessedArgument { {##1} } }
+ }
+\cs_generate_variant:Nn \__xparse_split_list_multi:nn { nV }
+\group_begin:
+\char_set_catcode_active:N \^^@
+\cs_new_protected:Npn \__xparse_split_list_single:Nn #1#2
+ {
+ \tl_set:Nn \l__xparse_split_list_tl {#2}
+ \group_begin:
+ \char_set_lccode:nn { `\^^@ } { `#1 }
+ \tex_lowercase:D
+ {
+ \group_end:
+ \tl_replace_all:Nnn \l__xparse_split_list_tl { ^^@ }
+ } {#1}
+ \__xparse_split_list_multi:nV {#1} \l__xparse_split_list_tl
+ }
+\group_end:
+\cs_new_protected:Npn \__xparse_split_argument:nnn #1#2#3
+ {
+ \__xparse_split_list:nn {#2} {#3}
+ \exp_args:Nf \__xparse_split_argument_aux:nnnn
+ { \tl_count:N \ProcessedArgument }
+ {#1} {#2} {#3}
+ }
+\cs_new_protected:Npn \__xparse_split_argument_aux:nnnn #1#2#3#4
+ {
+ \int_compare:nNnF {#1} = { #2 + 1 }
+ {
+ \int_compare:nNnTF {#1} > { #2 + 1 }
+ {
+ \tl_set:Nx \ProcessedArgument
+ {
+ \exp_last_unbraced:NnNo
+ \__xparse_split_argument_aux:n
+ { #2 + 1 }
+ \use_none_delimit_by_q_stop:w
+ \ProcessedArgument
+ \q_stop
+ }
+ \__kernel_msg_error:nnxxx { xparse } { split-excess-tokens }
+ { \tl_to_str:n {#3} } { \int_eval:n { #2 + 1 } }
+ { \tl_to_str:n {#4} }
+ }
+ {
+ \tl_put_right:Nx \ProcessedArgument
+ {
+ \prg_replicate:nn { #2 + 1 - (#1) }
+ { { \exp_not:V \c_novalue_tl } }
+ }
+ }
+ }
+ }
+\cs_new:Npn \__xparse_split_argument_aux:n #1
+ { \prg_replicate:nn {#1} { \__xparse_split_argument_aux:wn } }
+\cs_new:Npn \__xparse_split_argument_aux:wn #1 \use_none_delimit_by_q_stop:w #2
+ {
+ \exp_not:n { {#2} }
+ #1
+ \use_none_delimit_by_q_stop:w
+ }
+\cs_new_protected:Npn \__xparse_trim_spaces:n #1
+ { \tl_set:Nx \ProcessedArgument { \tl_trim_spaces:n {#1} } }
+\cs_new_protected:Npn \__xparse_get_arg_spec_error:N #1
+ {
+ \bool_set_false:N \l__xparse_environment_bool
+ \tl_set:Nn \l__xparse_fn_tl {#1}
+ \__xparse_get_arg_spec_error_aux:n { \cs_if_exist:NTF #1 }
+ }
+\cs_new_protected:Npn \__xparse_get_arg_spec_error:n #1
+ {
+ \bool_set_true:N \l__xparse_environment_bool
+ \str_set:Nx \l__xparse_environment_str {#1}
+ \__xparse_get_arg_spec_error_aux:n
+ { \cs_if_exist:cTF { \l__xparse_environment_str } }
+ }
+\cs_new_protected:Npn \__xparse_get_arg_spec_error_aux:n #1
+ {
+ #1
+ {
+ \__kernel_msg_error:nnx { xparse } { non-xparse }
+ { \__xparse_environment_or_command: }
+ }
+ {
+ \__kernel_msg_error:nnx { xparse } { unknown }
+ { \__xparse_environment_or_command: }
+ }
+ }
+\cs_new_protected:Npn \__xparse_get_arg_spec:NTF #1#2#3
+ {
+ \__xparse_cmd_if_xparse:NTF #1
+ {
+ \tl_set:Nx \ArgumentSpecification { \tl_item:Nn #1 { 2 } }
+ #2
+ }
+ {#3}
+ }
+\cs_new_protected:Npn \__xparse_get_arg_spec:N #1
+ {
+ \__xparse_get_arg_spec:NTF #1 { }
+ { \__xparse_get_arg_spec_error:N #1 }
+ }
+\cs_new_protected:Npn \__xparse_get_arg_spec:n #1
+ {
+ \exp_args:Nc \__xparse_get_arg_spec:NTF
+ { environment~ \tl_to_str:n {#1} }
+ { }
+ { \__xparse_get_arg_spec_error:n {#1} }
+ }
+\tl_new:N \ArgumentSpecification
+\cs_new_protected:Npn \__xparse_show_arg_spec:N #1
+ {
+ \__xparse_get_arg_spec:NTF #1
+ { \tl_show:N \ArgumentSpecification }
+ { \__xparse_get_arg_spec_error:N #1 }
+ }
+\cs_new_protected:Npn \__xparse_show_arg_spec:n #1
+ {
+ \exp_args:Nc \__xparse_get_arg_spec:NTF
+ { environment~ \tl_to_str:n {#1} }
+ { \tl_show:N \ArgumentSpecification }
+ { \__xparse_get_arg_spec_error:n {#1} }
+ }
+\cs_new_protected:Npn \__xparse_check_definable:nNT #1
+ { \tl_trim_spaces_apply:nN {#1} \__xparse_check_definable_aux:nN }
+\group_begin:
+ \char_set_catcode_active:n { `? }
+ \cs_new_protected:Npn \__xparse_check_definable_aux:nN #1#2
+ {
+ \group_begin:
+ \tl_if_single_token:nTF {#1}
+ {
+ \int_set:Nn \tex_escapechar:D { 92 }
+ \exp_args:Nx \tl_if_empty:nTF
+ { \exp_args:No \str_tail:n { \token_to_str:N #1 } }
+ {
+ \exp_args:Nx \char_set_lccode:nn
+ { ` \str_head:n {#1} } { `? }
+ \tex_lowercase:D { \tl_if_eq:nnTF {#1} } { ? }
+ { \group_end: \use_iii:nnn }
+ { \group_end: \use_i:nnn }
+ }
+ { \group_end: \use_iii:nnn }
+ }
+ { \group_end: \use_ii:nnn }
+ {
+ \__kernel_msg_error:nnxx { xparse } { not-definable }
+ { \tl_to_str:n {#1} } { \token_to_str:N #2 }
+ }
+ {
+ \__kernel_msg_error:nnxx { xparse } { not-one-token }
+ { \tl_to_str:n {#1} } { \token_to_str:N #2 }
+ }
+ }
+\group_end:
+\cs_new_protected:Npn \__xparse_token_if_cs:NTF #1
+ {
+ \group_begin:
+ \int_set:Nn \tex_escapechar:D { 92 }
+ \exp_args:Nx \tl_if_empty:nTF
+ { \exp_args:No \str_tail:n { \token_to_str:N #1 } }
+ { \group_end: \use_ii:nn }
+ { \group_end: \use_i:nn }
+ }
+\cs_new:Npn \__xparse_tl_mapthread_function:NNN #1#2#3
+ {
+ \exp_after:wN \exp_after:wN
+ \exp_after:wN \__xparse_tl_mapthread_loop:w
+ \exp_after:wN \exp_after:wN
+ \exp_after:wN #3
+ \exp_after:wN #1
+ \exp_after:wN \q_recursion_tail
+ \exp_after:wN \q_mark
+ #2
+ \q_recursion_tail
+ \q_recursion_stop
+ }
+\cs_new:Npn \__xparse_tl_mapthread_function:nnN #1#2#3
+ {
+ \__xparse_tl_mapthread_loop:w #3
+ #1 \q_recursion_tail \q_mark
+ #2 \q_recursion_tail \q_recursion_stop
+ }
+\cs_new:Npn \__xparse_tl_mapthread_loop:w #1#2#3 \q_mark #4
+ {
+ \quark_if_recursion_tail_stop:n {#2}
+ \quark_if_recursion_tail_stop:n {#4}
+ #1 {#2} {#4}
+ \__xparse_tl_mapthread_loop:w #1#3 \q_mark
+ }
+\cs_new_protected:Npn \__xparse_cmd_if_xparse:NTF #1
+ {
+ \exp_args:Nf \str_case_e:nnTF
+ {
+ \exp_args:Nf \tl_if_empty:nT { \cs_argument_spec:N #1 }
+ {
+ \exp_last_unbraced:Nf \__xparse_cmd_if_xparse_aux:w
+ { \cs_replacement_spec:N #1 } ~ \q_stop
+ }
+ }
+ {
+ { \token_to_str:N \__xparse_start:nNNnnn } { }
+ { \token_to_str:N \__xparse_start_expandable:nNNNNn } { }
+ { \token_to_str:N \__xparse_start_env:nnnnn } { }
+ }
+ }
+\cs_new:Npn \__xparse_cmd_if_xparse_aux:w #1 ~ #2 \q_stop {#1}
+\cs_new_protected:Npn \__xparse_peek_nonspace:NTF
+ { \__xparse_peek_nonspace_aux:nNNTF { } \__xparse_peek_meaning:NTF }
+\cs_new_protected:Npn \__xparse_peek_nonspace_remove:NTF
+ { \__xparse_peek_nonspace_aux:nNNTF { } \__xparse_peek_meaning_remove:NTF }
+\cs_new_protected:Npn \__xparse_peek_nonspace_aux:nNNTF #1#2#3#4#5
+ {
+ \peek_meaning_remove:NTF \c_space_token
+ { \__xparse_peek_nonspace_aux:nNNTF { #1 ~ } #2 #3 {#4} {#5} }
+ { #2 #3 { #4 } { #5 #1 } }
+ }
+\cs_new_protected:Npn \__xparse_peek_meaning:NTF
+ { \__xparse_peek_meaning_aux:NNTF \c_false_bool }
+\cs_new_protected:Npn \__xparse_peek_meaning_remove:NTF
+ { \__xparse_peek_meaning_aux:NNTF \c_true_bool }
+\cs_new_protected:Npn \__xparse_peek_meaning_aux:NNTF #1#2#3#4
+ {
+ \tl_set:Nn \l__xparse_tmpa_tl {#3}
+ \tl_set:Nn \l__xparse_tmpb_tl {#4}
+ \peek_meaning:NTF #2
+ {
+ \token_if_eq_meaning:NNTF #2 \c_group_begin_token
+ { \__xparse_peek_true_remove:Nw #1 }
+ {
+ \__xparse_token_if_cs:NTF #2
+ { \__xparse_peek_cs_check_equal:NNN #1 #2 }
+ { \__xparse_peek_true_remove:Nw #1 }
+ }
+ }
+ { \l__xparse_tmpb_tl }
+ }
+\cs_new_protected:Npn \__xparse_peek_cs_check_equal:NNN #1#2#3
+ {
+ \str_if_eq:nnTF {#2} {#3}
+ { \__xparse_peek_true_remove:Nw #1 }
+ { \l__xparse_tmpb_tl }
+ #3
+ }
+\cs_new_protected:Npn \__xparse_peek_true_remove:Nw #1
+ {
+ \bool_if:NTF #1
+ {
+ \tex_afterassignment:D \l__xparse_tmpa_tl
+ \cs_set_eq:NN \__xparse_tmp:w
+ }
+ { \l__xparse_tmpa_tl }
+ }
+\cs_new:Npn \__xparse_environment_or_command:
+ {
+ \bool_if:NTF \l__xparse_environment_bool
+ { environment ~ ' \l__xparse_environment_str ' }
+ {
+ command ~ '
+ \exp_args:Nf \tl_trim_spaces:n
+ { \exp_after:wN \token_to_str:N \l__xparse_fn_tl }
+ '
+ }
+ }
+\tl_const:Nn \c__xparse_ignore_def_tl
+ { \\ \\ LaTeX~will~ignore~this~entire~definition. }
+\__kernel_msg_new:nnnn { xparse } { arg-after-body }
+ { In~the~definition~of~#1,~b~(body)~argument~must~be~last. }
+ {
+ The~'body'~argument~type~is~followed~by~'#2'~in~the~argument~
+ specification~of~the~#1.~This~is~not~allowed.
+ \c__xparse_ignore_def_tl
+ }
+\__kernel_msg_new:nnnn { xparse } { bad-arg-spec }
+ { Bad~argument~specification~'#2'~for~#1. }
+ {
+ The~argument~specification~provided~was~not~valid:~
+ one~or~more~mandatory~pieces~of~information~were~missing.
+ \c__xparse_ignore_def_tl
+ }
+\__kernel_msg_new:nnnn { xparse } { command-already-defined }
+ { Command~'#1'~already~defined! }
+ {
+ You~have~used~#2~
+ with~a~command~that~already~has~a~definition. \\ \\
+ The~existing~definition~of~'#1'~will~not~be~altered.
+ }
+\__kernel_msg_new:nnnn { xparse } { command-not-yet-defined }
+ { Command ~'#1'~not~yet~defined! }
+ {
+ You~have~used~#2~
+ with~a~command~that~was~never~defined.
+ \c__xparse_ignore_def_tl
+ }
+\__kernel_msg_new:nnnn { xparse } { environment-already-defined }
+ { Environment~'#1'~already~defined! }
+ {
+ You~have~used~\NewDocumentEnvironment
+ with~an~environment~that~already~has~a~definition. \\ \\
+ The~existing~definition~of~'#1'~will~not~be~altered.
+ }
+\__kernel_msg_new:nnnn { xparse } { environment-not-yet-defined }
+ { Environment~'#1'~not~yet~defined! }
+ {
+ You~have~used~\RenewDocumentEnvironment
+ with~an~environment~that~was~never~defined.
+ \c__xparse_ignore_def_tl
+ }
+\__kernel_msg_new:nnnn { xparse } { expandable-ending-optional }
+ {
+ Argument~specification~'#2'~for~expandable~command~'#1'~
+ ends~with~optional~argument.
+ }
+ {
+ Expandable~commands~must~have~a~final~mandatory~argument~
+ (or~no~arguments~at~all).~You~cannot~have~a~terminal~optional~
+ argument~with~expandable~commands.
+ }
+\__kernel_msg_new:nnnn { xparse } { inconsistent-long }
+ { Inconsistent~long~arguments~for~expandable~command~'#1'. }
+ {
+ The~arguments~for~an~expandable~command~must~not~involve~short~
+ arguments~after~long~arguments.~You~have~tried~to~mix~the~two~types.
+ }
+\__kernel_msg_new:nnnn { xparse } { invalid-command-arg }
+ { Argument~type~'#2'~not~available~for~#1. }
+ {
+ The~letter~'#2'~can~only~be~used~in~environment~argument~
+ specifications,~not~for~commands.
+ \\ \\
+ LaTeX~will~ignore~this~entire~definition.
+ }
+\__kernel_msg_new:nnnn { xparse } { invalid-expandable-argument-type }
+ { Argument~type~'#2'~not~available~for~expandable~command~'#1'. }
+ {
+ The~letter~'#2'~specifies~an~argument~type~which~cannot~be~used~
+ in~an~expandable~command.
+ \c__xparse_ignore_def_tl
+ }
+\__kernel_msg_new:nnnn { xparse } { invalid-after-optional-expandably }
+ {
+ Argument~type~'#2'~not~available~after~optional~argument~
+ for~expandable~command~'#1'.
+ }
+ {
+ The~letter~'#2'~specifies~an~argument~type~which~cannot~be~used~
+ in~an~expandable~command~after~an~optional~argument.
+ \c__xparse_ignore_def_tl
+ }
+\__kernel_msg_new:nnnn { xparse } { non-trailing-obey-spaces }
+ { Prefix~'!'~used~before~mandatory~argument~'#2'~of~#1. }
+ {
+ The~prefix~'!'~can~only~apply~to~trailing~optional~arguments.
+ \c__xparse_ignore_def_tl
+ }
+\__kernel_msg_new:nnnn { xparse } { not-definable }
+ { First~argument~of~'#2'~must~be~a~command. }
+ {
+ The~first~argument~of~'#2'~should~be~the~document~command~that~will~
+ be~defined.~The~provided~argument~'#1'~is~a~character.~Perhaps~a~
+ backslash~is~missing?
+ \c__xparse_ignore_def_tl
+ }
+\__kernel_msg_new:nnnn { xparse } { not-one-token }
+ { First~argument~of~'#2'~must~be~a~command. }
+ {
+ The~first~argument~of~'#2'~should~be~the~document~command~that~will~
+ be~defined.~The~provided~argument~'#1'~contains~more~than~one~
+ token.~Perhaps~a~backslash~is~missing?
+ \c__xparse_ignore_def_tl
+ }
+\__kernel_msg_new:nnnn { xparse } { not-single-token }
+ {
+ Argument~delimiter~'#2'~for~the~#1~should~be~
+ a~single~non-space~token.
+ }
+ {
+ The~argument~specification~provided~was~not~valid:~in~a~place~
+ where~a~single~token~is~required,~LaTeX~found~'#2'.
+ \c__xparse_ignore_def_tl
+ }
+\__kernel_msg_new:nnnn { xparse } { forbidden-implicit-group-token }
+ { Argument~delimiter~'#2'~for~the~#1~is~not~allowed. }
+ {
+ The~argument~specification~provided~was~not~valid:~the~implicit~
+ #3-group~token~'#2'~is~not~allowed~as~an~argument~delimiter.
+ \c__xparse_ignore_def_tl
+ }
+\__kernel_msg_new:nnnn { xparse } { processor-in-expandable }
+ { Argument~processor~'>{#2}'~cannot~be~used~for~the~expandable~command~'#1'. }
+ {
+ The~argument~specification~for~#1~contains~a~processor~function:~
+ this~is~only~supported~for~standard~robust~commands.
+ \c__xparse_ignore_def_tl
+ }
+\__kernel_msg_new:nnnn { xparse } { too-many-arguments }
+ { Too~many~arguments~in~argument~specification~'#2'~of~#1. }
+ {
+ The~argument~specification~provided~has~more~than~9~arguments.~
+ This~cannot~be~implemented.
+ \c__xparse_ignore_def_tl
+ }
+\__kernel_msg_new:nnnn { xparse } { two-markers }
+ { Two~'#2'~apply~to~the~same~argument~in~argument~specification~of~#1. }
+ {
+ The~argument~specification~provided~has~two~markers~'#2'~applying~
+ to~the~same~argument;~these~are~redundant.
+ }
+\__kernel_msg_new:nnnn { xparse } { unknown-argument-type }
+ { Unknown~argument~type~'#2'~for~the~#1. }
+ {
+ The~letter~'#2'~does~not~specify~a~known~argument~type.
+ \c__xparse_ignore_def_tl
+ }
+\__kernel_msg_new:nnnn { xparse } { xparse-argument-type }
+ { Deprecated~argument~type~'#2'~for~the~#1~requires~xparse. }
+ {
+ The~letter~'#2'~specifies~a~known~argument~type~that~requires~
+ the~xparse~package.
+ \c__xparse_ignore_def_tl
+ }
+\__kernel_msg_new:nnn { xparse } { if-boolean }
+ { Invalid~use~\iow_char:N\\IfBooleanTF~{#1} }
+\__kernel_msg_new:nnnn { xparse } { loop-in-defaults }
+ { Defaults~of~#1~have~circular~dependency. }
+ {
+ The~default~values~of~two~or~more~arguments~of~the~#1~
+ depend~on~each~other~in~a~way~that~cannot~be~resolved.
+ }
+\__kernel_msg_new:nnnn { xparse } { missing-required }
+ { Missing~required~argument~for~#1. }
+ {
+ The~current~#1~expects~an~argument~starting~with~'#2'.~
+ LaTeX~did~not~find~it,~and~will~insert~a~default~value~to~be~processed.
+ }
+\__kernel_msg_new:nnnn { xparse } { non-xparse }
+ { \str_uppercase:n #1~not~defined~using~xparse. }
+ {
+ You~have~asked~for~the~argument~specification~for~the~#1,~
+ but~this~was~not~defined~using~xparse.
+ }
+\__kernel_msg_new:nnnn { xparse } { split-excess-tokens }
+ { Too~many~'#1'~tokens~when~trying~to~split~argument. }
+ {
+ LaTeX~was~asked~to~split~the~input~'#3'~
+ at~each~occurrence~of~the~token~'#1',~up~to~a~maximum~of~#2~parts.~
+ There~were~too~many~'#1'~tokens.
+ }
+\__kernel_msg_new:nnnn { xparse } { unknown }
+ { Unknown~document~#1. }
+ {
+ You~have~asked~for~the~argument~specification~for~the~#1,~
+ but~it~is~not~defined.
+ }
+\__kernel_msg_new:nnnn { xparse } { verbatim-newline }
+ { Verbatim~argument~of~#1~ended~by~end~of~line. }
+ {
+ The~verbatim~argument~of~the~#1~cannot~contain~more~than~one~line,~
+ but~the~end~
+ of~the~current~line~has~been~reached.~You~may~have~forgotten~the~
+ closing~delimiter.
+ \\ \\
+ LaTeX~will~ignore~'#2'.
+ }
+\__kernel_msg_new:nnnn { xparse } { verbatim-tokenized }
+ { The~verbatim~#1~cannot~be~used~inside~an~argument. }
+ {
+ The~#1~takes~a~verbatim~argument.~
+ It~may~not~appear~within~the~argument~of~another~function.~
+ It~received~an~illegal~token \tl_if_empty:nF {#3} { ~'#3' } .
+ \\ \\
+ LaTeX~will~ignore~'#2'.
+ }
+\__kernel_msg_new:nnn { xparse } { define-command }
+ {
+ Defining~command~#1~
+ with~sig.~'#2'~\msg_line_context:.
+ }
+\__kernel_msg_new:nnn { xparse } { define-environment }
+ {
+ Defining~environment~'#1'~
+ with~sig.~'#2'~\msg_line_context:.
+ }
+\__kernel_msg_new:nnn { xparse } { redefine-command }
+ {
+ Redefining~command~#1~
+ with~sig.~'#2'~\msg_line_context:.
+ }
+\__kernel_msg_new:nnn { xparse } { redefine-environment }
+ {
+ Redefining~environment~'#1'~
+ with~sig.~'#2'~\msg_line_context:.
+ }
+\__kernel_msg_new:nnn { xparse } { optional-mandatory }
+ {
+ Since~the~mandatory~argument~'#1'~has~the~same~delimiter~'#2'~
+ as~a~previous~optional~argument,~it~will~not~be~possible~to~
+ omit~all~optional~arguments~when~calling~this~command.
+ }
+\__kernel_msg_new:nnn { xparse } { unsupported-let }
+ {
+ The~command~'#1'~was~undefined~but~not~the~associated~commands~
+ '#1~code'~and/or~'#1~defaults'.~Maybe~you~tried~using~
+ \iow_char:N\\let.~This~may~lead~to~an~infinite~loop.
+ }
+\cs_new_eq:NN \BooleanFalse \c_false_bool
+\cs_new_eq:NN \BooleanTrue \c_true_bool
+\cs_new_protected:Npn \NewDocumentCommand #1#2#3
+ {
+ \__xparse_check_definable:nNT {#1} \NewDocumentCommand
+ {
+ \cs_if_exist:NTF #1
+ {
+ \__kernel_msg_error:nnxx { xparse } { command-already-defined }
+ { \use:nnn \token_to_str:N #1 { } }
+ { \token_to_str:N \NewDocumentCommand }
+ }
+ { \__xparse_declare_cmd:Nnn #1 {#2} {#3} }
+ }
+ }
+\cs_new_protected:Npn \RenewDocumentCommand #1#2#3
+ {
+ \__xparse_check_definable:nNT {#1} \RenewDocumentCommand
+ {
+ \cs_if_exist:NTF #1
+ { \__xparse_declare_cmd:Nnn #1 {#2} {#3} }
+ {
+ \__kernel_msg_error:nnxx { xparse } { command-not-yet-defined }
+ { \use:nnn \token_to_str:N #1 { } }
+ { \token_to_str:N \RenewDocumentCommand }
+ }
+ }
+ }
+\cs_new_protected:Npn \ProvideDocumentCommand #1#2#3
+ {
+ \__xparse_check_definable:nNT {#1} \ProvideDocumentCommand
+ { \cs_if_exist:NF #1 { \__xparse_declare_cmd:Nnn #1 {#2} {#3} } }
+ }
+\cs_new_protected:Npn \DeclareDocumentCommand #1#2#3
+ {
+ \__xparse_check_definable:nNT {#1} \DeclareDocumentCommand
+ { \__xparse_declare_cmd:Nnn #1 {#2} {#3} }
+ }
+\cs_new_protected:Npn \NewDocumentEnvironment #1#2#3#4
+ {
+ \cs_if_exist:cTF {#1}
+ { \__kernel_msg_error:nnx { xparse } { environment-already-defined } {#1} }
+ { \__xparse_declare_env:nnnn {#1} {#2} {#3} {#4} }
+ }
+\cs_new_protected:Npn \RenewDocumentEnvironment #1#2#3#4
+ {
+ \cs_if_exist:cTF {#1}
+ { \__xparse_declare_env:nnnn {#1} {#2} {#3} {#4} }
+ { \__kernel_msg_error:nnx { xparse } { environment-not-yet-defined } {#1} }
+ }
+\cs_new_protected:Npn \ProvideDocumentEnvironment #1#2#3#4
+ { \cs_if_exist:cF {#1} { \__xparse_declare_env:nnnn {#1} {#2} {#3} {#4} } }
+\cs_new_protected:Npn \DeclareDocumentEnvironment #1#2#3#4
+ { \__xparse_declare_env:nnnn {#1} {#2} {#3} {#4} }
+\cs_new_protected:Npn \NewExpandableDocumentCommand #1#2#3
+ {
+ \__xparse_check_definable:nNT {#1} \NewExpandableDocumentCommand
+ {
+ \cs_if_exist:NTF #1
+ {
+ \__kernel_msg_error:nnxx { xparse } { command-already-defined }
+ { \use:nnn \token_to_str:N #1 { } }
+ { \token_to_str:N \NewExpandableDocumentCommand }
+ }
+ { \__xparse_declare_expandable_cmd:Nnn #1 {#2} {#3} }
+ }
+ }
+\cs_new_protected:Npn \RenewExpandableDocumentCommand #1#2#3
+ {
+ \__xparse_check_definable:nNT {#1} \RenewExpandableDocumentCommand
+ {
+ \cs_if_exist:NTF #1
+ { \__xparse_declare_expandable_cmd:Nnn #1 {#2} {#3} }
+ {
+ \__kernel_msg_error:nnxx { xparse } { command-not-yet-defined }
+ { \use:nnn \token_to_str:N #1 { } }
+ { \token_to_str:N \RenewExpandableDocumentCommand }
+ }
+ }
+ }
+\cs_new_protected:Npn \ProvideExpandableDocumentCommand #1#2#3
+ {
+ \__xparse_check_definable:nNT {#1} \ProvideExpandableDocumentCommand
+ {
+ \cs_if_exist:NF #1
+ { \__xparse_declare_expandable_cmd:Nnn #1 {#2} {#3} }
+ }
+ }
+\cs_new_protected:Npn \DeclareExpandableDocumentCommand #1#2#3
+ {
+ \__xparse_check_definable:nNT {#1} \DeclareExpandableDocumentCommand
+ { \__xparse_declare_expandable_cmd:Nnn #1 {#2} {#3} }
+ }
+\cs_new:Npn \IfBooleanTF #1
+ {
+ \tl_if_single:nF {#1}
+ { \prg_break:n { \use:n } }
+ \tl_if_single_token:nF #1
+ { \prg_break:n { \use:n } }
+ \token_if_eq_meaning:NNT #1 \c_true_bool
+ { \prg_break:n { \use_ii:nnn } }
+ \token_if_eq_meaning:NNT #1 \c_false_bool
+ { \prg_break:n { \use_iii:nnn } }
+ \prg_break:n { \use:n }
+ \prg_break_point:
+ {
+ \__kernel_msg_expandable_error:nnn { xparse } { if-boolean } {#1}
+ \use_ii:nn
+ }
+ }
+\cs_new:Npn \IfBooleanT #1#2 { \IfBooleanTF {#1} {#2} { } }
+\cs_new:Npn \IfBooleanF #1 { \IfBooleanTF {#1} { } }
+\cs_new_eq:NN \IfNoValueF \tl_if_novalue:nF
+\cs_new_eq:NN \IfNoValueT \tl_if_novalue:nT
+\cs_new_eq:NN \IfNoValueTF \tl_if_novalue:nTF
+\cs_new:Npn \IfValueF { \tl_if_novalue:nT }
+\cs_new:Npn \IfValueT { \tl_if_novalue:nF }
+\cs_new:Npn \IfValueTF #1#2#3 { \tl_if_novalue:nTF {#1} {#3} {#2} }
+\tl_new:N \ProcessedArgument
+\cs_new_eq:NN \ReverseBoolean \__xparse_bool_reverse:N
+\cs_new_eq:NN \SplitArgument \__xparse_split_argument:nnn
+\cs_new_eq:NN \SplitList \__xparse_split_list:nn
+\cs_new_eq:NN \TrimSpaces \__xparse_trim_spaces:n
+\cs_new_eq:NN \ProcessList \tl_map_function:nN
+\cs_new_protected:Npn \GetDocumentCommandArgSpec #1
+ {
+ \__xparse_check_definable:nNT {#1} \GetDocumentCommandArgSpec
+ { \__xparse_get_arg_spec:N #1 }
+ }
+\cs_new_eq:NN \GetDocumentEnvironmentArgSpec \__xparse_get_arg_spec:n
+\cs_new_protected:Npn \ShowDocumentCommandArgSpec #1
+ {
+ \__xparse_check_definable:nNT {#1} \ShowDocumentCommandArgSpec
+ { \__xparse_show_arg_spec:N #1 }
+ }
+\cs_new_eq:NN \ShowDocumentEnvironmentArgSpec \__xparse_show_arg_spec:n
+\__xparse_file_end_hook:
+%%
+%%
+%% End of file `xparse-generic.tex'.
diff --git a/Master/texmf-dist/tex/latex/l3packages/xparse/xparse.ltx b/Master/texmf-dist/tex/latex/l3packages/xparse/xparse.ltx
index 1ebd28dafc7..84bb42f2ac1 100644
--- a/Master/texmf-dist/tex/latex/l3packages/xparse/xparse.ltx
+++ b/Master/texmf-dist/tex/latex/l3packages/xparse/xparse.ltx
@@ -23,6 +23,7 @@
\message{xparse <2020-03-03>}%
}
\ExplSyntaxOn
+\file_input:n { xparse-generic.tex }
\tl_new:N \l__xparse_arg_spec_tl
\tl_new:N \l__xparse_args_tl
\tl_new:N \l__xparse_args_i_tl
@@ -190,7 +191,6 @@
\str_set:Nx \l__xparse_environment_str {#1}
\str_set:Nx \l__xparse_environment_str
{ \tl_trim_spaces:o { \l__xparse_environment_str } }
- \cs_if_exist:cTF { \l__xparse_environment_str }
{
\__kernel_msg_info:nnxx { xparse } { redefine-environment }
{ \l__xparse_environment_str } { \tl_to_str:n {#2} }
@@ -221,13 +221,10 @@
\cs_generate_from_arg_count:cNnn
{ environment~ #1 ~end~aux~ } \cs_set:Npn
\l__xparse_current_arg_int {#4}
- \cs_set_eq:cc {#1} { environment~ #1 }
- \cs_set_eq:cc { end #1 } { environment~ #1 ~end }
}
}
\cs_new_protected:Npn \__xparse_start_env:nnnnn #1#2
{
- \cs_if_exist_use:N \conditionally@traceoff
\str_set:Nn \l__xparse_environment_str {#2}
\bool_set_true:N \l__xparse_environment_bool
\__xparse_start_aux:ccnnnn
@@ -237,7 +234,6 @@
}
\cs_new_protected:Npx \__xparse_start:nNNnnn #1#2#3
{
- \exp_not:n { \cs_if_exist_use:N \conditionally@traceoff }
\exp_not:c { xparse~function~is~not~expandable }
\exp_not:n { \bool_set_false:N \l__xparse_environment_bool }
\exp_not:N \__xparse_start_aux:NNnnnn
@@ -257,7 +253,6 @@
{
\tl_if_empty:NF \l__xparse_defaults_tl { \__xparse_defaults: }
\tl_if_empty:NF \l__xparse_process_all_tl { \__xparse_args_process: }
- \cs_if_exist_use:N \conditionally@traceon
\exp_after:wN \l__xparse_fn_code_tl \l__xparse_args_tl
}
\cs_new_protected:Npn \__xparse_defaults:
@@ -416,8 +411,21 @@
\int_incr:N \l__xparse_current_arg_int
\cs_if_exist_use:cF { __xparse_normalize_type_ \tl_to_str:n {#1} :w }
{
- \__kernel_msg_error:nnxx { xparse } { unknown-argument-type }
- { \__xparse_environment_or_command: } { \tl_to_str:n {#1} }
+ \bool_lazy_any:nTF
+ {
+ { \str_if_eq_p:nn {#1} { G } }
+ { \str_if_eq_p:nn {#1} { g } }
+ { \str_if_eq_p:nn {#1} { l } }
+ { \str_if_eq_p:nn {#1} { u } }
+ }
+ {
+ \__kernel_msg_error:nnxx { xparse } { xparse-argument-type }
+ { \__xparse_environment_or_command: } { \tl_to_str:n {#1} }
+ }
+ {
+ \__kernel_msg_error:nnxx { xparse } { unknown-argument-type }
+ { \__xparse_environment_or_command: } { \tl_to_str:n {#1} }
+ }
\__xparse_bad_def:wn
}
}
@@ -433,8 +441,6 @@
\quark_if_recursion_tail_stop_do:nn {##1} { \__xparse_bad_arg_spec:wn }
\__xparse_normalize_type_E:w {##1} { }
}
- \cs_new_protected:Npn \__xparse_normalize_type_g:w
- { \__xparse_normalize_type_G:w {#1} }
\cs_new_protected:Npn \__xparse_normalize_type_o:w
{ \__xparse_normalize_type_D:w [ ] {#1} }
\cs_new_protected:Npn \__xparse_normalize_type_O:w
@@ -522,14 +528,6 @@
\__xparse_normalize_E_unique_check:w #2 \q_stop
}
}
-\cs_new_protected:Npn \__xparse_normalize_type_G:w #1
- {
- \quark_if_recursion_tail_stop_do:nn {#1} { \__xparse_bad_arg_spec:wn }
- \__xparse_normalize_check_gv:N G
- \__xparse_add_arg_spec:n { G {#1} }
- \tl_put_right:Nn \l__xparse_last_delimiters_tl { { } }
- \__xparse_normalize_arg_spec_loop:n
- }
\cs_new_protected:Npn \__xparse_normalize_type_t:w #1
{
\quark_if_recursion_tail_stop_do:Nn #1 { \__xparse_bad_arg_spec:wn }
@@ -545,12 +543,6 @@
\bool_set_false:N \l__xparse_long_bool
\__xparse_normalize_arg_spec_loop:n
}
-\cs_new_protected:Npn \__xparse_normalize_type_l:w
- {
- \__xparse_normalize_check_lu:N l
- \__xparse_add_arg_spec_mandatory:n { l }
- \__xparse_normalize_arg_spec_loop:n
- }
\cs_new_protected:Npn \__xparse_normalize_type_m:w
{
\__xparse_delimiter_check:nnn { } { m } { \iow_char:N \{ }
@@ -567,13 +559,6 @@
\__xparse_add_arg_spec_mandatory:n { R #1 #2 {#3} }
\__xparse_normalize_arg_spec_loop:n
}
-\cs_new_protected:Npn \__xparse_normalize_type_u:w #1
- {
- \quark_if_recursion_tail_stop_do:nn {#1} { \__xparse_bad_arg_spec:wn }
- \__xparse_normalize_check_lu:N u
- \__xparse_add_arg_spec_mandatory:n { u {#1} }
- \__xparse_normalize_arg_spec_loop:n
- }
\cs_new_protected:Npn \__xparse_normalize_type_v:w
{
\__xparse_normalize_check_gv:N v
@@ -779,20 +764,6 @@
\tl_put_right:Nn \l__xparse_signature_tl { {#1} }
\__xparse_prepare_signature:N
}
-\cs_new_protected:Npn \__xparse_add_type_G:w #1
- {
- \__xparse_flush_m_args:
- \__xparse_add_default:n {#1}
- \__xparse_add_grabber:N G
- \__xparse_prepare_signature:N
- }
-\cs_new_protected:Npn \__xparse_add_type_l:w
- {
- \__xparse_flush_m_args:
- \__xparse_add_default:
- \__xparse_add_grabber:N l
- \__xparse_prepare_signature:N
- }
\cs_new_protected:Npn \__xparse_add_type_m:w
{
\__xparse_add_default:
@@ -817,14 +788,6 @@
\tl_put_right:Nn \l__xparse_signature_tl {#1}
\__xparse_prepare_signature:N
}
-\cs_new_protected:Npn \__xparse_add_type_u:w #1
- {
- \__xparse_flush_m_args:
- \__xparse_add_default:
- \__xparse_add_grabber:N u
- \tl_put_right:Nn \l__xparse_signature_tl { {#1} }
- \__xparse_prepare_signature:N
- }
\cs_new_protected:Npn \__xparse_add_type_v:w
{
\__xparse_flush_m_args:
@@ -946,8 +909,6 @@
\tl_put_right:Nx \l__xparse_tmpb_tl
{ \exp_not:o \l__xparse_tmpa_tl \exp_not:N #1 }
}
-\cs_new_protected:Npn \__xparse_add_expandable_type_l:w
- { \__xparse_add_expandable_type_u:w ## }
\cs_new_protected:Npn \__xparse_add_expandable_type_m:w
{
\__xparse_add_default:
@@ -968,18 +929,6 @@
}
\__xparse_prepare_signature:N
}
-\cs_new_protected:Npn \__xparse_add_expandable_type_u:w #1
- {
- \__xparse_add_default:
- \bool_if:NTF \l__xparse_long_bool
- { \cs_set:cpn }
- { \cs_set_nopar:cpn }
- { \l__xparse_expandable_aux_name_tl } ##1 \q__xparse ##2 ##3 ##4 #1
- { ##1 {##4} \q__xparse ##2 ##3 }
- \__xparse_add_expandable_grabber:nn { u }
- { \exp_not:c { \l__xparse_expandable_aux_name_tl } }
- \__xparse_prepare_signature:N
- }
\cs_new_protected:Npn \__xparse_add_expandable_grabber:nn #1#2
{
\tl_put_right:Nx \l__xparse_signature_tl
@@ -1201,46 +1150,6 @@
}
}
\cs_new_protected:Npn \__xparse_grab_E_finalise: { }
-\cs_new_protected:Npn \__xparse_grab_G:w #1 \__xparse_run_code:
- {
- \__xparse_grab_G_aux:nNN {#1} \cs_set_protected_nopar:Npn
- \__xparse_peek_nonspace:NTF
- }
-\cs_new_protected:Npn \__xparse_grab_G_long:w #1 \__xparse_run_code:
- {
- \__xparse_grab_G_aux:nNN {#1} \cs_set_protected:Npn
- \__xparse_peek_nonspace:NTF
- }
-\cs_new_protected:Npn \__xparse_grab_G_obey_spaces:w #1 \__xparse_run_code:
- {
- \__xparse_grab_G_aux:nNN {#1} \cs_set_protected_nopar:Npn
- \peek_meaning:NTF
- }
-\cs_new_protected:Npn \__xparse_grab_G_long_obey_spaces:w #1 \__xparse_run_code:
- {
- \__xparse_grab_G_aux:nNN {#1} \cs_set_protected:Npn
- \peek_meaning:NTF
- }
-\cs_new_protected:Npn \__xparse_grab_G_aux:nNN #1#2#3
- {
- \tl_set:Nn \l__xparse_signature_tl {#1}
- \exp_after:wN #2 \l__xparse_fn_tl ##1
- { \__xparse_add_arg:n {##1} }
- #3 \c_group_begin_token
- { \l__xparse_fn_tl }
- { \__xparse_add_arg:o \c_novalue_tl }
- }
-\cs_new_protected:Npn \__xparse_grab_l:w #1 \__xparse_run_code:
- { \__xparse_grab_l_aux:nN {#1} \cs_set_protected_nopar:Npn }
-\cs_new_protected:Npn \__xparse_grab_l_long:w #1 \__xparse_run_code:
- { \__xparse_grab_l_aux:nN {#1} \cs_set_protected:Npn }
-\cs_new_protected:Npn \__xparse_grab_l_aux:nN #1#2
- {
- \tl_set:Nn \l__xparse_signature_tl {#1}
- \exp_after:wN #2 \l__xparse_fn_tl ##1##
- { \__xparse_add_arg:n {##1} }
- \l__xparse_fn_tl
- }
\cs_new_protected:Npn \__xparse_grab_m:w #1 \__xparse_run_code:
{
\tl_set:Nn \l__xparse_signature_tl {#1}
@@ -1345,17 +1254,6 @@
}
\l__xparse_fn_tl
}
-\cs_new_protected:Npn \__xparse_grab_u:w #1#2 \__xparse_run_code:
- { \__xparse_grab_u_aux:nnN {#1} {#2} \cs_set_protected_nopar:Npn }
-\cs_new_protected:Npn \__xparse_grab_u_long:w #1#2 \__xparse_run_code:
- { \__xparse_grab_u_aux:nnN {#1} {#2} \cs_set_protected:Npn }
-\cs_new_protected:Npn \__xparse_grab_u_aux:nnN #1#2#3
- {
- \tl_set:Nn \l__xparse_signature_tl {#2}
- \exp_after:wN #3 \l__xparse_fn_tl ##1 #1
- { \__xparse_add_arg:n {##1} }
- \l__xparse_fn_tl
- }
\tl_new:N \l__xparse_v_arg_tl
\cs_new_protected:Npn \__xparse_grab_v:w
{
@@ -1468,8 +1366,6 @@
}
\cs_new_protected:Npn \__xparse_grab_v_aux_catcodes:
{
- \cs_set_eq:NN \do \char_set_catcode_other:N
- \dospecials
\tex_endlinechar:D = `\^^M \scan_stop:
\bool_if:NTF \l__xparse_long_bool
{ \char_set_catcode_other:n { \tex_endlinechar:D } }
@@ -2143,6 +2039,13 @@
The~letter~'#2'~does~not~specify~a~known~argument~type.
\c__xparse_ignore_def_tl
}
+\__kernel_msg_new:nnnn { xparse } { xparse-argument-type }
+ { Deprecated~argument~type~'#2'~for~the~#1~requires~xparse. }
+ {
+ The~letter~'#2'~specifies~a~known~argument~type~that~requires~
+ the~xparse~package.
+ \c__xparse_ignore_def_tl
+ }
\__kernel_msg_new:nnn { xparse } { if-boolean }
{ Invalid~use~\iow_char:N\\IfBooleanTF~{#1} }
\__kernel_msg_new:nnnn { xparse } { loop-in-defaults }
diff --git a/Master/texmf-dist/tex/latex/l3packages/xparse/xparse.sty b/Master/texmf-dist/tex/latex/l3packages/xparse/xparse.sty
index a38311e8686..7c446d6a360 100644
--- a/Master/texmf-dist/tex/latex/l3packages/xparse/xparse.sty
+++ b/Master/texmf-dist/tex/latex/l3packages/xparse/xparse.sty
@@ -32,7 +32,7 @@
}%
\endinput
}
-\ProvidesExplPackage{xparse}{2020-03-06}{}
+\ProvidesExplPackage{xparse}{2020-05-14}{}
{L3 Experimental document command parser}
\clist_new:N \l__xparse_options_clist
\DeclareOption* { \clist_put_right:NV \l__xparse_options_clist \CurrentOption }
@@ -45,396 +45,8 @@
\keys_set:nV { xparse } \l__xparse_options_clist
\bool_if:NF \l__xparse_log_bool
{ \msg_redirect_module:nnn { LaTeX / xparse } { info } { none } }
-\cs_if_exist:NT \NewDocumentCommand
- { \file_input_stop: }
-\tl_new:N \l__xparse_arg_spec_tl
-\tl_new:N \l__xparse_args_tl
-\tl_new:N \l__xparse_args_i_tl
-\tl_new:N \l__xparse_args_ii_tl
-\int_new:N \l__xparse_current_arg_int
-\bool_new:N \l__xparse_defaults_bool
-\tl_new:N \l__xparse_defaults_tl
-\bool_new:N \l__xparse_environment_bool
-\str_new:N \l__xparse_environment_str
-\bool_new:N \l__xparse_expandable_bool
-\tl_new:N \l__xparse_expandable_aux_name_tl
-\tl_set:Nn \l__xparse_expandable_aux_name_tl
- {
- \l__xparse_function_tl \c_space_tl
- ( arg~ \int_use:N \l__xparse_current_arg_int )
- }
-\int_new:N \g__xparse_grabber_int
-\tl_new:N \l__xparse_fn_tl
-\tl_new:N \l__xparse_fn_code_tl
-\tl_new:N \l__xparse_function_tl
-\bool_new:N \l__xparse_grab_expandably_bool
-\bool_new:N \l__xparse_obey_spaces_bool
-\tl_new:N \l__xparse_last_delimiters_tl
-\bool_new:N \l__xparse_long_bool
-\int_new:N \l__xparse_m_args_int
-\bool_new:N \l__xparse_prefixed_bool
-\tl_new:N \l__xparse_process_all_tl
-\tl_new:N \l__xparse_process_one_tl
-\bool_new:N \l__xparse_process_some_bool
-\tl_new:N \l__xparse_saved_args_tl
-\tl_new:N \l__xparse_signature_tl
-\bool_new:N \l__xparse_some_obey_spaces_bool
-\bool_new:N \l__xparse_some_long_bool
-\bool_new:N \l__xparse_some_short_bool
-\prop_new:N \l__xparse_tmp_prop
-\tl_new:N \l__xparse_tmpa_tl
-\tl_new:N \l__xparse_tmpb_tl
-\cs_new_eq:NN \__xparse_tmp:w ?
-\cs_new_protected:Npn \__xparse_declare_cmd:Nnn
- {
- \bool_set_false:N \l__xparse_expandable_bool
- \__xparse_declare_cmd_aux:Nnn
- }
-\cs_new_protected:Npn \__xparse_declare_expandable_cmd:Nnn
- {
- \bool_set_true:N \l__xparse_expandable_bool
- \__xparse_declare_cmd_aux:Nnn
- }
-\cs_new_protected:Npn \__xparse_declare_cmd_aux:Nnn #1#2#3
- {
- \cs_if_exist:NTF #1
- {
- \__kernel_msg_info:nnxx { xparse } { redefine-command }
- { \token_to_str:N #1 } { \tl_to_str:n {#2} }
- }
- {
- \bool_lazy_or:nnT
- { \cs_if_exist_p:c { \cs_to_str:N #1 ~ code } }
- { \cs_if_exist_p:c { \cs_to_str:N #1 ~ defaults } }
- {
- \__kernel_msg_warning:nnx { xparse } { unsupported-let }
- { \token_to_str:N #1 }
- }
- \__kernel_msg_info:nnxx { xparse } { define-command }
- { \token_to_str:N #1 } { \tl_to_str:n {#2} }
- }
- \bool_set_false:N \l__xparse_environment_bool
- \__xparse_declare_cmd_internal:Nnnn #1 {#2} {#3} { }
- }
-\cs_new_protected:Npn \__xparse_declare_cmd_internal:Nnnn #1#2#3#4
- {
- \tl_set:Nx \l__xparse_function_tl { \cs_to_str:N #1 }
- \tl_set:Nx \l__xparse_fn_tl
- { \exp_not:c { \l__xparse_function_tl \c_space_tl } }
- \__xparse_normalize_arg_spec:n {#2}
- \exp_args:No \__xparse_prepare_signature:n \l__xparse_arg_spec_tl
- \__xparse_declare_cmd_code:Nnn #1 {#2} {#3}
- #4
- \__xparse_break_point:n {#2}
- }
-\cs_generate_variant:Nn \__xparse_declare_cmd_internal:Nnnn { cnx }
-\cs_new_eq:NN \__xparse_break_point:n \use_none:n
-\cs_new_protected:Npn \__xparse_declare_cmd_code:Nnn
- {
- \bool_if:NTF \l__xparse_grab_expandably_bool
- { \__xparse_declare_cmd_code_expandable:Nnn }
- { \__xparse_declare_cmd_code_aux:Nnn }
- }
-\cs_new_protected:Npn \__xparse_declare_cmd_code_aux:Nnn #1#2#3
- {
- \cs_generate_from_arg_count:cNnn
- { \l__xparse_function_tl \c_space_tl code }
- \cs_set_protected:Npn \l__xparse_current_arg_int {#3}
- \cs_set_protected_nopar:Npx #1
- {
- \bool_if:NTF \l__xparse_environment_bool
- {
- \__xparse_start_env:nnnnn { \exp_not:n {#2} }
- { \l__xparse_environment_str }
- }
- {
- \__xparse_start:nNNnnn { \exp_not:n {#2} }
- \exp_not:c { \l__xparse_function_tl \c_space_tl }
- \exp_not:c { \l__xparse_function_tl \c_space_tl code }
- }
- { \exp_not:o \l__xparse_signature_tl }
- {
- \bool_if:NT \l__xparse_defaults_bool
- { \exp_not:o \l__xparse_defaults_tl }
- }
- {
- \bool_if:NT \l__xparse_process_some_bool
- { \exp_not:o \l__xparse_process_all_tl }
- }
- }
- }
-\cs_new_protected:Npn \__xparse_declare_cmd_code_expandable:Nnn #1#2#3
- {
- \exp_args:Ncc \cs_generate_from_arg_count:NNnn
- { \l__xparse_function_tl \c_space_tl code }
- { cs_set \bool_if:NF \l__xparse_expandable_bool { _protected } :Npn }
- \l__xparse_current_arg_int {#3}
- \bool_if:NT \l__xparse_defaults_bool
- {
- \use:x
- {
- \cs_generate_from_arg_count:cNnn
- { \l__xparse_function_tl \c_space_tl defaults }
- \cs_set:Npn \l__xparse_current_arg_int
- { \exp_not:o \l__xparse_defaults_tl }
- }
- }
- \bool_if:NTF \l__xparse_expandable_bool
- { \cs_set_nopar:Npx } { \cs_set_protected_nopar:Npx } #1
- {
- \exp_not:N \__xparse_start_expandable:nNNNNn
- { \exp_not:n {#2} }
- \exp_not:c { \l__xparse_function_tl \c_space_tl }
- \exp_not:c
- {
- \l__xparse_function_tl \c_space_tl
- \bool_if:NT \l__xparse_some_short_bool
- { \bool_if:NT \l__xparse_some_long_bool { \c_space_tl } }
- }
- \exp_not:c { \l__xparse_function_tl \c_space_tl code }
- \bool_if:NTF \l__xparse_defaults_bool
- { \exp_not:c { \l__xparse_function_tl \c_space_tl defaults } }
- { ? }
- { \exp_not:o \l__xparse_signature_tl }
- }
- \bool_if:NTF \l__xparse_some_long_bool
- {
- \bool_if:NT \l__xparse_some_short_bool
- {
- \cs_set_nopar:cpx { \l__xparse_function_tl \c_space_tl \c_space_tl }
- ##1##2 { ##1 {##2} }
- }
- \cs_set:cpx
- }
- { \cs_set_nopar:cpx }
- { \l__xparse_function_tl \c_space_tl } ##1##2 { ##1 {##2} }
- }
-\cs_new_protected:Npn \__xparse_declare_env:nnnn #1#2
- {
- \str_set:Nx \l__xparse_environment_str {#1}
- \str_set:Nx \l__xparse_environment_str
- { \tl_trim_spaces:o { \l__xparse_environment_str } }
- \cs_if_exist:cTF { \l__xparse_environment_str }
- {
- \__kernel_msg_info:nnxx { xparse } { redefine-environment }
- { \l__xparse_environment_str } { \tl_to_str:n {#2} }
- }
- {
- \__kernel_msg_info:nnxx { xparse } { define-environment }
- { \l__xparse_environment_str } { \tl_to_str:n {#2} }
- }
- \bool_set_false:N \l__xparse_expandable_bool
- \bool_set_true:N \l__xparse_environment_bool
- \exp_args:NV \__xparse_declare_env_internal:nnnn
- \l__xparse_environment_str {#2}
- }
-\cs_new_protected:Npn \__xparse_declare_env_internal:nnnn #1#2#3#4
- {
- \__xparse_declare_cmd_internal:cnxn { environment~ #1 } {#2}
- {
- \cs_set_nopar:Npx \exp_not:c { environment~ #1 ~end~aux }
- {
- \exp_not:N \exp_not:N \exp_not:c { environment~ #1~end~aux~ }
- \exp_not:n { \exp_not:o \l__xparse_args_tl }
- }
- \exp_not:n {#3}
- }
- {
- \cs_set_nopar:cpx { environment~ #1 ~end }
- { \exp_not:c { environment~ #1 ~end~aux } }
- \cs_generate_from_arg_count:cNnn
- { environment~ #1 ~end~aux~ } \cs_set:Npn
- \l__xparse_current_arg_int {#4}
- \cs_set_eq:cc {#1} { environment~ #1 }
- \cs_set_eq:cc { end #1 } { environment~ #1 ~end }
- }
- }
-\cs_new_protected:Npn \__xparse_start_env:nnnnn #1#2
- {
- \cs_if_exist_use:N \conditionally@traceoff
- \str_set:Nn \l__xparse_environment_str {#2}
- \bool_set_true:N \l__xparse_environment_bool
- \__xparse_start_aux:ccnnnn
- { environment~ \l__xparse_environment_str \c_space_tl }
- { environment~ \l__xparse_environment_str \c_space_tl code }
- {#1}
- }
-\cs_new_protected:Npx \__xparse_start:nNNnnn #1#2#3
- {
- \exp_not:n { \cs_if_exist_use:N \conditionally@traceoff }
- \exp_not:c { xparse~function~is~not~expandable }
- \exp_not:n { \bool_set_false:N \l__xparse_environment_bool }
- \exp_not:N \__xparse_start_aux:NNnnnn
- #2 #3 {#1}
- }
-\cs_new_protected:Npn \__xparse_start_aux:NNnnnn #1#2#3#4#5#6
- {
- \tl_clear:N \l__xparse_args_tl
- \tl_set:Nn \l__xparse_fn_tl {#1}
- \tl_set:Nn \l__xparse_fn_code_tl {#2}
- \tl_set:Nn \l__xparse_defaults_tl {#5}
- \tl_set:Nn \l__xparse_process_all_tl {#6}
- #4 \__xparse_run_code:
- }
-\cs_generate_variant:Nn \__xparse_start_aux:NNnnnn { cc }
-\cs_new_protected:Npn \__xparse_run_code:
- {
- \tl_if_empty:NF \l__xparse_defaults_tl { \__xparse_defaults: }
- \tl_if_empty:NF \l__xparse_process_all_tl { \__xparse_args_process: }
- \cs_if_exist_use:N \conditionally@traceon
- \exp_after:wN \l__xparse_fn_code_tl \l__xparse_args_tl
- }
-\cs_new_protected:Npn \__xparse_defaults:
- {
- \__xparse_defaults_def:
- \tl_set_eq:NN \l__xparse_args_i_tl \l__xparse_args_tl
- \__xparse_defaults_aux: \__xparse_defaults_aux: \__xparse_defaults_aux:
- \__xparse_defaults_aux: \__xparse_defaults_aux: \__xparse_defaults_aux:
- \__xparse_defaults_aux: \__xparse_defaults_aux: \__xparse_defaults_aux:
- \__xparse_defaults_error:w
- \q_recursion_stop
- \tl_set_eq:NN \l__xparse_args_tl \l__xparse_args_i_tl
- }
-\cs_new_protected:Npn \__xparse_defaults_aux:
- {
- \tl_set:Nx \l__xparse_args_ii_tl
- { \exp_after:wN \__xparse_tmp:w \l__xparse_args_i_tl }
- \tl_if_eq:NNT \l__xparse_args_ii_tl \l__xparse_args_i_tl
- { \use_none_delimit_by_q_recursion_stop:w }
- \tl_set_eq:NN \l__xparse_args_i_tl \l__xparse_args_ii_tl
- }
-\cs_new_protected:Npn \__xparse_defaults_error:w \q_recursion_stop
- {
- \__kernel_msg_error:nnx { xparse } { loop-in-defaults }
- { \__xparse_environment_or_command: }
- }
-\cs_new_protected:Npn \__xparse_defaults_def:
- {
- \tl_clear:N \l__xparse_tmpa_tl
- \int_zero:N \l__xparse_current_arg_int
- \__xparse_tl_mapthread_function:NNN \l__xparse_args_tl \l__xparse_defaults_tl
- \__xparse_defaults_def:nn
- \cs_generate_from_arg_count:NNVo \__xparse_tmp:w \cs_set:Npn
- \l__xparse_current_arg_int \l__xparse_tmpa_tl
- }
-\cs_generate_variant:Nn \cs_generate_from_arg_count:NNnn { NNVo }
-\cs_new_protected:Npn \__xparse_defaults_def:nn
- {
- \int_incr:N \l__xparse_current_arg_int
- \exp_args:NV \__xparse_defaults_def:nnn \l__xparse_current_arg_int
- }
-\cs_new_protected:Npn \__xparse_defaults_def:nnn #1#2#3
- {
- \tl_put_right:Nx \l__xparse_tmpa_tl
- {
- {
- \exp_not:N \exp_not:n
- {
- \tl_if_novalue:nTF {#2}
- { \exp_not:o {#3} }
- { \exp_not:n { ## #1 } }
- }
- }
- }
- }
-\cs_new_protected:Npn \__xparse_args_process:
- {
- \tl_clear:N \l__xparse_args_ii_tl
- \__xparse_tl_mapthread_function:NNN
- \l__xparse_args_tl
- \l__xparse_process_all_tl
- \__xparse_args_process_loop:nn
- \tl_set_eq:NN \l__xparse_args_tl \l__xparse_args_ii_tl
- }
-\cs_new_protected:Npn \__xparse_args_process_loop:nn #1#2
- {
- \tl_set:Nn \ProcessedArgument {#1}
- \tl_if_novalue:nF {#1}
- { \tl_map_function:nN {#2} \__xparse_args_process_aux:n }
- \tl_put_right:No \l__xparse_args_ii_tl
- { \exp_after:wN { \ProcessedArgument } }
- }
-\cs_new_protected:Npn \__xparse_args_process_aux:n #1
- {
- \cs_generate_from_arg_count:NNnn \__xparse_tmp:w \cs_set:Npn
- { \tl_count:N \l__xparse_args_tl } {#1}
- \exp_args:NNNo \exp_after:wN \__xparse_tmp:w \l__xparse_args_tl
- { \ProcessedArgument }
- }
-\cs_new:Npn \__xparse_start_expandable:nNNNNn #1#2#3#4#5#6
- { #6 \__xparse_end_expandable:NNw #5 #4 \q__xparse #2#3 }
-\cs_new:Npn \__xparse_end_expandable:NNw #1#2
- { \__xparse_end_expandable_aux:w #1#2 \prg_do_nothing: }
-\cs_new:Npn \__xparse_end_expandable_aux:w #1#2#3 \q__xparse
- { \exp_args:No \__xparse_end_expandable_aux:nNNNN {#3} #1 #2 }
-\cs_new:Npn \__xparse_end_expandable_aux:nNNNN #1#2#3#4#5
- {
- \token_if_eq_charcode:NNT ? #2 { \exp_after:wN \use_iv:nnnn }
- \__xparse_end_expandable_defaults:nnnNNn {#1} { } {#1} #2#3
- { } { } { } { } { } { } { } { } { } { }
- {
- \__kernel_msg_expandable_error:nnf
- { xparse } { loop-in-defaults }
- { \exp_args:Nf \tl_trim_spaces:n { \token_to_str:N #4 } }
- \use_iv:nnnn
- }
- \q_stop
- }
-\cs_new:Npn \__xparse_end_expandable_defaults:nnnNNn #1#2#3#4#5#6
- {
- #6
- \str_if_eq:nnTF {#1} {#2}
- { \use_i_delimit_by_q_stop:nw { #5 #1 } }
- {
- \exp_args:No \__xparse_tl_mapthread_function:nnN
- { #4 #1 } {#3}
- \__xparse_end_expandable_defaults:nnw
- \__xparse_end_expandable_defaults:nnnNNn { } {#1} {#3} #4 #5
- }
- }
-\cs_new:Npn \__xparse_end_expandable_defaults:nnw #1#2
- {
- \tl_if_novalue:nTF {#2}
- { \exp_args:No \__xparse_end_expandable_defaults:nw {#1} }
- { \__xparse_end_expandable_defaults:nw {#2} }
- }
-\cs_new:Npn \__xparse_end_expandable_defaults:nw
- #1#2 \__xparse_end_expandable_defaults:nnnNNn #3
- { #2 \__xparse_end_expandable_defaults:nnnNNn { #3 {#1} } }
-\cs_new_protected:Npn \__xparse_normalize_arg_spec:n #1
- {
- \int_zero:N \l__xparse_current_arg_int
- \tl_clear:N \l__xparse_last_delimiters_tl
- \tl_clear:N \l__xparse_arg_spec_tl
- \bool_set_true:N \l__xparse_grab_expandably_bool
- \bool_set_false:N \l__xparse_obey_spaces_bool
- \bool_set_false:N \l__xparse_long_bool
- \bool_set_false:N \l__xparse_some_obey_spaces_bool
- \bool_set_false:N \l__xparse_some_long_bool
- \bool_set_false:N \l__xparse_some_short_bool
- \__xparse_normalize_arg_spec_loop:n #1
- \q_recursion_tail \q_recursion_tail \q_recursion_tail \q_recursion_stop
- \int_compare:nNnT \l__xparse_current_arg_int > 9
- {
- \__kernel_msg_error:nnxx { xparse } { too-many-arguments }
- { \__xparse_environment_or_command: } { \tl_to_str:n {#1} }
- \__xparse_bad_def:wn
- }
- \bool_if:NT \l__xparse_expandable_bool
- {
- \tl_if_empty:NF \l__xparse_last_delimiters_tl
- {
- \__kernel_msg_error:nnxx { xparse } { expandable-ending-optional }
- { \iow_char:N \\ \l__xparse_function_tl } { \tl_to_str:n {#1} }
- \__xparse_bad_def:wn
- }
- }
- \bool_if:NT \l__xparse_expandable_bool
- { \bool_set_true:N \l__xparse_grab_expandably_bool }
- \bool_if:NT \l__xparse_environment_bool
- { \bool_set_false:N \l__xparse_grab_expandably_bool }
- }
-\cs_new_protected:Npn \__xparse_normalize_arg_spec_loop:n #1
+\file_input:n { xparse-generic.tex }
+\cs_gset_protected:Npn \__xparse_normalize_arg_spec_loop:n #1
{
\quark_if_recursion_tail_stop:n {#1}
\int_incr:N \l__xparse_current_arg_int
@@ -445,107 +57,8 @@
\__xparse_bad_def:wn
}
}
-\cs_set_protected:Npn \__xparse_tmp:w #1
- {
- \cs_new_protected:Npn \__xparse_normalize_type_d:w ##1##2
- {
- \quark_if_recursion_tail_stop_do:nn {##2} { \__xparse_bad_arg_spec:wn }
- \__xparse_normalize_type_D:w {##1} {##2} {#1}
- }
- \cs_new_protected:Npn \__xparse_normalize_type_e:w ##1
- {
- \quark_if_recursion_tail_stop_do:nn {##1} { \__xparse_bad_arg_spec:wn }
- \__xparse_normalize_type_E:w {##1} { }
- }
- \cs_new_protected:Npn \__xparse_normalize_type_g:w
- { \__xparse_normalize_type_G:w {#1} }
- \cs_new_protected:Npn \__xparse_normalize_type_o:w
- { \__xparse_normalize_type_D:w [ ] {#1} }
- \cs_new_protected:Npn \__xparse_normalize_type_O:w
- { \__xparse_normalize_type_D:w [ ] }
- \cs_new_protected:Npn \__xparse_normalize_type_r:w ##1##2
- {
- \quark_if_recursion_tail_stop_do:nn {##2} { \__xparse_bad_arg_spec:wn }
- \__xparse_normalize_type_R:w {##1} {##2} {#1}
- }
- \cs_new_protected:Npn \__xparse_normalize_type_s:w
- { \__xparse_normalize_type_t:w * }
- }
-\exp_args:No \__xparse_tmp:w { \c_novalue_tl }
-\cs_new_protected:cpn { __xparse_normalize_type_>:w } #1#2
- {
- \quark_if_recursion_tail_stop_do:nn {#2} { \__xparse_bad_arg_spec:wn }
- \bool_if:NT \l__xparse_expandable_bool
- {
- \__kernel_msg_error:nnxx { xparse } { processor-in-expandable }
- { \iow_char:N \\ \l__xparse_function_tl } { \tl_to_str:n {#1} }
- \__xparse_bad_def:wn
- }
- \tl_put_right:Nx \l__xparse_arg_spec_tl { > { \tl_trim_spaces:n {#1} } }
- \int_decr:N \l__xparse_current_arg_int
- \bool_set_false:N \l__xparse_grab_expandably_bool
- \__xparse_normalize_arg_spec_loop:n {#2}
- }
-\cs_new_protected:cpn { __xparse_normalize_type_+:w } #1
- {
- \quark_if_recursion_tail_stop_do:nn {#1} { \__xparse_bad_arg_spec:wn }
- \bool_if:NT \l__xparse_long_bool
- {
- \__kernel_msg_error:nnxx { xparse } { two-markers }
- { \__xparse_environment_or_command: } { + }
- \__xparse_bad_def:wn
- }
- \bool_set_true:N \l__xparse_long_bool
- \int_decr:N \l__xparse_current_arg_int
- \__xparse_normalize_arg_spec_loop:n {#1}
- }
-\cs_new_protected:cpn { __xparse_normalize_type_!:w } #1
- {
- \quark_if_recursion_tail_stop_do:nn {#1} { \__xparse_bad_arg_spec:wn }
- \bool_if:NT \l__xparse_obey_spaces_bool
- {
- \__kernel_msg_error:nnxx { xparse } { two-markers }
- { \__xparse_environment_or_command: } { ! }
- \__xparse_bad_def:wn
- }
- \bool_set_true:N \l__xparse_obey_spaces_bool
- \bool_set_true:N \l__xparse_some_obey_spaces_bool
- \int_decr:N \l__xparse_current_arg_int
- \__xparse_normalize_arg_spec_loop:n {#1}
- }
-\cs_new_protected:Npn \__xparse_normalize_type_D:w #1#2#3
- {
- \quark_if_recursion_tail_stop_do:nn {#3} { \__xparse_bad_arg_spec:wn }
- \__xparse_single_token_check:n {#1} \__xparse_allowed_token_check:N #1
- \__xparse_single_token_check:n {#2}
- \__xparse_add_arg_spec:n { D #1 #2 {#3} }
- \tl_put_right:Nn \l__xparse_last_delimiters_tl {#1}
- \bool_set_false:N \l__xparse_grab_expandably_bool
- \__xparse_normalize_arg_spec_loop:n
- }
-\cs_new_protected:Npn \__xparse_normalize_type_E:w #1#2
- {
- \quark_if_recursion_tail_stop_do:nn {#2} { \__xparse_bad_arg_spec:wn }
- \tl_if_blank:nT {#1} { \__xparse_bad_arg_spec:wn }
- \tl_map_function:nN {#1} \__xparse_single_token_check:n
- \tl_map_function:nN {#1} \__xparse_allowed_token_check:N
- \__xparse_normalize_E_unique_check:w #1 \q_nil \q_stop
- \int_compare:nNnT { \tl_count:n {#2} } > { \tl_count:n {#1} }
- { \__xparse_bad_arg_spec:wn }
- \__xparse_add_arg_spec:n { E {#1} {#2} }
- \tl_put_right:Nn \l__xparse_last_delimiters_tl {#1}
- \bool_set_false:N \l__xparse_grab_expandably_bool
- \int_add:Nn \l__xparse_current_arg_int { \tl_count:n {#1} - 1 }
- \__xparse_normalize_arg_spec_loop:n
- }
-\cs_new_protected:Npn \__xparse_normalize_E_unique_check:w #1#2 \q_stop
- {
- \quark_if_nil:NF #1
- {
- \tl_if_in:nnT {#2} {#1} { \__xparse_bad_arg_spec:wn }
- \__xparse_normalize_E_unique_check:w #2 \q_stop
- }
- }
+\cs_new_protected:Npx \__xparse_normalize_type_g:w
+ { \exp_not:N \__xparse_normalize_type_G:w { \exp_not:V \c_novalue_tl } }
\cs_new_protected:Npn \__xparse_normalize_type_G:w #1
{
\quark_if_recursion_tail_stop_do:nn {#1} { \__xparse_bad_arg_spec:wn }
@@ -554,43 +67,12 @@
\tl_put_right:Nn \l__xparse_last_delimiters_tl { { } }
\__xparse_normalize_arg_spec_loop:n
}
-\cs_new_protected:Npn \__xparse_normalize_type_t:w #1
- {
- \quark_if_recursion_tail_stop_do:Nn #1 { \__xparse_bad_arg_spec:wn }
- \__xparse_single_token_check:n {#1} \__xparse_allowed_token_check:N #1
- \tl_put_right:Nx \l__xparse_arg_spec_tl
- {
- \bool_if:NT \l__xparse_obey_spaces_bool { ! }
- t \exp_not:n {#1}
- }
- \tl_put_right:Nn \l__xparse_last_delimiters_tl {#1}
- \bool_set_false:N \l__xparse_grab_expandably_bool
- \bool_set_false:N \l__xparse_obey_spaces_bool
- \bool_set_false:N \l__xparse_long_bool
- \__xparse_normalize_arg_spec_loop:n
- }
\cs_new_protected:Npn \__xparse_normalize_type_l:w
{
\__xparse_normalize_check_lu:N l
\__xparse_add_arg_spec_mandatory:n { l }
\__xparse_normalize_arg_spec_loop:n
}
-\cs_new_protected:Npn \__xparse_normalize_type_m:w
- {
- \__xparse_delimiter_check:nnn { } { m } { \iow_char:N \{ }
- \__xparse_add_arg_spec_mandatory:n { m }
- \__xparse_normalize_arg_spec_loop:n
- }
-\cs_new_protected:Npn \__xparse_normalize_type_R:w #1#2#3
- {
- \quark_if_recursion_tail_stop_do:nn {#3} { \__xparse_bad_arg_spec:wn }
- \__xparse_single_token_check:n {#1} \__xparse_allowed_token_check:N #1
- \__xparse_single_token_check:n {#2}
- \__xparse_delimiter_check:nnn {#1} { R/r } { \tl_to_str:n {#1} }
- \bool_set_false:N \l__xparse_grab_expandably_bool
- \__xparse_add_arg_spec_mandatory:n { R #1 #2 {#3} }
- \__xparse_normalize_arg_spec_loop:n
- }
\cs_new_protected:Npn \__xparse_normalize_type_u:w #1
{
\quark_if_recursion_tail_stop_do:nn {#1} { \__xparse_bad_arg_spec:wn }
@@ -598,211 +80,6 @@
\__xparse_add_arg_spec_mandatory:n { u {#1} }
\__xparse_normalize_arg_spec_loop:n
}
-\cs_new_protected:Npn \__xparse_normalize_type_v:w
- {
- \__xparse_normalize_check_gv:N v
- \__xparse_add_arg_spec_mandatory:n { v }
- \__xparse_normalize_arg_spec_loop:n
- }
-\cs_new_protected:Npn \__xparse_normalize_type_b:w #1
- {
- \bool_if:NF \l__xparse_environment_bool
- {
- \__kernel_msg_error:nnxx
- { xparse } { invalid-command-arg }
- { \__xparse_environment_or_command: } { b }
- \__xparse_bad_def:wn
- }
- \tl_clear:N \l__xparse_last_delimiters_tl
- \__xparse_add_arg_spec:n { b }
- \quark_if_recursion_tail_stop:n {#1}
- \__kernel_msg_error:nnxx { xparse } { arg-after-body }
- { \__xparse_environment_or_command: }
- { \tl_to_str:n {#1} }
- \__xparse_bad_def:wn
- }
-\cs_new_protected:Npn \__xparse_single_token_check:n #1
- {
- \tl_trim_spaces_apply:nN {#1} \tl_if_single_token:nF
- {
- \__kernel_msg_error:nnxx { xparse } { not-single-token }
- { \__xparse_environment_or_command: } { \tl_to_str:n {#1} }
- \__xparse_bad_def:wn
- }
- }
-\cs_new_protected:Npn \__xparse_allowed_token_check:N #1
- {
- \token_if_eq_meaning:NNTF #1 \c_group_begin_token
- { \use:n }
- {
- \token_if_eq_meaning:NNTF #1 \c_group_end_token
- { \use:n }
- { \use_none:n }
- }
- {
- \__kernel_msg_error:nnxxx
- { xparse } { forbidden-implicit-group-token }
- { \__xparse_environment_or_command: } { \tl_to_str:n {#1} }
- {
- \token_if_eq_meaning:NNTF #1 \c_group_begin_token
- { begin } { end }
- }
- \__xparse_bad_def:wn
- }
- }
-\cs_new_protected:Npn \__xparse_normalize_check_gv:N #1
- {
- \bool_if:NT \l__xparse_expandable_bool
- {
- \__kernel_msg_error:nnxx
- { xparse } { invalid-expandable-argument-type }
- { \iow_char:N \\ \l__xparse_function_tl } { \tl_to_str:n {#1} }
- \__xparse_bad_def:wn
- }
- \bool_set_false:N \l__xparse_grab_expandably_bool
- }
-\cs_new_protected:Npn \__xparse_normalize_check_lu:N #1
- {
- \bool_if:NT \l__xparse_expandable_bool
- {
- \tl_if_empty:NF \l__xparse_last_delimiters_tl
- {
- \__kernel_msg_error:nnxx
- { xparse } { invalid-after-optional-expandably }
- { \iow_char:N \\ \l__xparse_function_tl } { \tl_to_str:n {#1} }
- \__xparse_bad_def:wn
- }
- }
- }
-\cs_new_protected:Npn \__xparse_delimiter_check:nnn #1#2#3
- {
- \tl_map_inline:Nn \l__xparse_last_delimiters_tl
- {
- \tl_if_eq:nnT {##1} {#1}
- {
- \__kernel_msg_warning:nnxx { xparse } { optional-mandatory }
- {#2} {#3}
- }
- }
- }
-\cs_new_protected:Npn \__xparse_bad_arg_spec:wn #1 \__xparse_break_point:n #2
- {
- \__kernel_msg_error:nnxx { xparse } { bad-arg-spec }
- { \__xparse_environment_or_command: } { \tl_to_str:n {#2} }
- }
-\cs_new_protected:Npn \__xparse_bad_def:wn #1 \__xparse_break_point:n #2 { }
-\cs_new_protected:Npn \__xparse_add_arg_spec:n #1
- {
- \bool_lazy_and:nnT
- { ! \l__xparse_long_bool }
- { \l__xparse_some_long_bool }
- {
- \bool_if:NT \l__xparse_expandable_bool
- {
- \__kernel_msg_error:nnx { xparse } { inconsistent-long }
- { \iow_char:N \\ \l__xparse_function_tl }
- \__xparse_bad_def:wn
- }
- \bool_set_false:N \l__xparse_grab_expandably_bool
- }
- \bool_if:NTF \l__xparse_long_bool
- { \bool_set_true:N \l__xparse_some_long_bool }
- { \bool_set_true:N \l__xparse_some_short_bool }
- \tl_put_right:Nx \l__xparse_arg_spec_tl
- {
- \bool_if:NT \l__xparse_long_bool { + }
- \bool_if:NT \l__xparse_obey_spaces_bool { ! }
- \exp_not:n {#1}
- }
- \bool_set_false:N \l__xparse_long_bool
- \bool_set_false:N \l__xparse_obey_spaces_bool
- }
-\cs_new_protected:Npn \__xparse_add_arg_spec_mandatory:n #1
- {
- \bool_if:NT \l__xparse_some_obey_spaces_bool
- {
- \__kernel_msg_error:nnxx { xparse } { non-trailing-obey-spaces }
- { \__xparse_environment_or_command: } { \tl_to_str:n {#1} }
- \__xparse_bad_def:wn
- }
- \tl_clear:N \l__xparse_last_delimiters_tl
- \__xparse_add_arg_spec:n {#1}
- }
-\cs_new_protected:Npn \__xparse_prepare_signature:n #1
- {
- \int_zero:N \l__xparse_current_arg_int
- \bool_set_false:N \l__xparse_long_bool
- \bool_set_false:N \l__xparse_obey_spaces_bool
- \int_zero:N \l__xparse_m_args_int
- \bool_set_false:N \l__xparse_defaults_bool
- \tl_clear:N \l__xparse_defaults_tl
- \tl_clear:N \l__xparse_process_all_tl
- \tl_clear:N \l__xparse_process_one_tl
- \bool_set_false:N \l__xparse_process_some_bool
- \tl_clear:N \l__xparse_signature_tl
- \__xparse_prepare_signature:N #1 \q_recursion_tail \q_recursion_stop
- \bool_if:NF \l__xparse_expandable_bool { \__xparse_flush_m_args: }
- }
-\cs_new_protected:Npn \__xparse_prepare_signature:N
- {
- \bool_set_false:N \l__xparse_prefixed_bool
- \__xparse_prepare_signature_bypass:N
- }
-\cs_new_protected:Npn \__xparse_prepare_signature_bypass:N #1
- {
- \quark_if_recursion_tail_stop:N #1
- \use:c
- {
- __xparse_add
- \bool_if:NT \l__xparse_grab_expandably_bool { _expandable }
- _type_ \token_to_str:N #1 :w
- }
- }
-\cs_new_protected:cpn { __xparse_add_type_+:w }
- {
- \__xparse_flush_m_args:
- \bool_set_true:N \l__xparse_long_bool
- \bool_set_true:N \l__xparse_prefixed_bool
- \__xparse_prepare_signature_bypass:N
- }
-\cs_new_protected:cpn { __xparse_add_type_!:w }
- {
- \__xparse_flush_m_args:
- \bool_set_true:N \l__xparse_obey_spaces_bool
- \bool_set_true:N \l__xparse_prefixed_bool
- \__xparse_prepare_signature_bypass:N
- }
-\cs_new_protected:cpn { __xparse_add_type_>:w } #1
- {
- \__xparse_flush_m_args:
- \bool_set_true:N \l__xparse_prefixed_bool
- \bool_set_true:N \l__xparse_process_some_bool
- \tl_put_left:Nn \l__xparse_process_one_tl { {#1} }
- \__xparse_prepare_signature_bypass:N
- }
-\cs_new_protected:Npn \__xparse_add_type_b:w
- {
- \__xparse_flush_m_args:
- \__xparse_add_default:
- \__xparse_add_grabber:N b
- \__xparse_prepare_signature:N
- }
-\cs_new_protected:Npn \__xparse_add_type_D:w #1#2#3
- {
- \__xparse_flush_m_args:
- \__xparse_add_default:n {#3}
- \__xparse_add_grabber:N D
- \tl_put_right:Nn \l__xparse_signature_tl { #1 #2 }
- \__xparse_prepare_signature:N
- }
-\cs_new_protected:Npn \__xparse_add_type_E:w #1#2
- {
- \__xparse_flush_m_args:
- \__xparse_add_default_E:nn {#1} {#2}
- \__xparse_add_grabber:N E
- \tl_put_right:Nn \l__xparse_signature_tl { {#1} }
- \__xparse_prepare_signature:N
- }
\cs_new_protected:Npn \__xparse_add_type_G:w #1
{
\__xparse_flush_m_args:
@@ -817,30 +94,6 @@
\__xparse_add_grabber:N l
\__xparse_prepare_signature:N
}
-\cs_new_protected:Npn \__xparse_add_type_m:w
- {
- \__xparse_add_default:
- \bool_if:NTF \l__xparse_prefixed_bool
- { \__xparse_add_grabber:N m }
- { \int_incr:N \l__xparse_m_args_int }
- \__xparse_prepare_signature:N
- }
-\cs_new_protected:Npn \__xparse_add_type_R:w #1#2#3
- {
- \__xparse_flush_m_args:
- \__xparse_add_default:n {#3}
- \__xparse_add_grabber:N R
- \tl_put_right:Nn \l__xparse_signature_tl { #1 #2 }
- \__xparse_prepare_signature:N
- }
-\cs_new_protected:Npn \__xparse_add_type_t:w #1
- {
- \__xparse_flush_m_args:
- \__xparse_add_default:
- \__xparse_add_grabber:N t
- \tl_put_right:Nn \l__xparse_signature_tl {#1}
- \__xparse_prepare_signature:N
- }
\cs_new_protected:Npn \__xparse_add_type_u:w #1
{
\__xparse_flush_m_args:
@@ -849,149 +102,8 @@
\tl_put_right:Nn \l__xparse_signature_tl { {#1} }
\__xparse_prepare_signature:N
}
-\cs_new_protected:Npn \__xparse_add_type_v:w
- {
- \__xparse_flush_m_args:
- \exp_args:No \__xparse_add_default:n \c_novalue_tl
- \__xparse_add_grabber:N v
- \__xparse_prepare_signature:N
- }
-\cs_new_protected:Npn \__xparse_flush_m_args:
- {
- \int_compare:nNnT \l__xparse_m_args_int > 0
- {
- \tl_put_right:Nx \l__xparse_signature_tl
- { \exp_not:c { __xparse_grab_m_ \int_use:N \l__xparse_m_args_int :w } }
- \tl_put_right:Nx \l__xparse_process_all_tl
- { \prg_replicate:nn { \l__xparse_m_args_int } { { } } }
- }
- \int_zero:N \l__xparse_m_args_int
- }
-\cs_new_protected:Npn \__xparse_add_grabber:N #1
- {
- \tl_put_right:Nx \l__xparse_signature_tl
- {
- \exp_not:c
- {
- __xparse_grab_ #1
- \bool_if:NT \l__xparse_long_bool { _long }
- \bool_if:NT \l__xparse_obey_spaces_bool { _obey_spaces }
- :w
- }
- }
- \bool_set_false:N \l__xparse_long_bool
- \bool_set_false:N \l__xparse_obey_spaces_bool
- \tl_put_right:Nx \l__xparse_process_all_tl
- { { \exp_not:o \l__xparse_process_one_tl } }
- \tl_clear:N \l__xparse_process_one_tl
- }
-\cs_new_protected:Npn \__xparse_add_default:n #1
- {
- \tl_if_novalue:nTF {#1}
- { \__xparse_add_default: }
- {
- \int_incr:N \l__xparse_current_arg_int
- \bool_set_true:N \l__xparse_defaults_bool
- \tl_put_right:Nn \l__xparse_defaults_tl { { \prg_do_nothing: #1 } }
- }
- }
-\cs_new_protected:Npn \__xparse_add_default:
- {
- \int_incr:N \l__xparse_current_arg_int
- \tl_put_right:Nn \l__xparse_defaults_tl { \c_novalue_tl }
- }
-\cs_new_protected:Npn \__xparse_add_default_E:nn #1#2
- {
- \tl_map_function:nN {#2} \__xparse_add_default:n
- \prg_replicate:nn
- { \tl_count:n {#1} - \tl_count:n {#2} }
- { \__xparse_add_default: }
- }
-\cs_new_protected:cpn { __xparse_add_expandable_type_+:w }
- {
- \bool_set_true:N \l__xparse_long_bool
- \__xparse_prepare_signature:N
- }
-\cs_new_protected:Npn \__xparse_add_expandable_type_D:w
- { \__xparse_add_expandable_type_D_aux:NNNn D }
-\cs_new_protected:Npn \__xparse_add_expandable_type_D_aux:NNNn #1#2#3#4
- {
- \__xparse_add_default:n {#4}
- \tl_if_eq:nnTF {#2} {#3}
- { \__xparse_add_expandable_type_D_aux:NN #1 #2 }
- { \__xparse_add_expandable_type_D_aux:NNN #1 #2 #3 }
- \__xparse_prepare_signature:N
- }
-\cs_new_protected:Npn \__xparse_add_expandable_type_D_aux:NNN #1#2#3
- {
- \bool_if:NTF \l__xparse_long_bool
- { \cs_set:cpx }
- { \cs_set_nopar:cpx }
- { \l__xparse_expandable_aux_name_tl } ##1 ##2 #2 ##3 \q__xparse ##4 #3
- { ##1 {##2} {##3} {##4} }
- \__xparse_add_expandable_grabber:nn {#1}
- {
- \exp_not:c { \l__xparse_expandable_aux_name_tl }
- \exp_not:n { #2 #3 }
- }
- }
-\cs_new_protected:Npn \__xparse_add_expandable_type_D_aux:NN #1#2
- {
- \bool_if:NTF \l__xparse_long_bool
- { \cs_set:cpx }
- { \cs_set_nopar:cpx }
- { \l__xparse_expandable_aux_name_tl } ##1 #2 ##2 #2
- { ##1 {##2} }
- \__xparse_add_expandable_grabber:nn { #1_alt }
- {
- \exp_not:c { \l__xparse_expandable_aux_name_tl }
- \exp_not:n {#2}
- }
- }
-\cs_new_protected:Npn \__xparse_add_expandable_type_E:w #1#2
- {
- \__xparse_add_default_E:nn {#1} {#2}
- \tl_clear:N \l__xparse_tmpb_tl
- \tl_map_function:nN {#1} \__xparse_add_expandable_type_E_aux:n
- \__xparse_add_expandable_grabber:nn
- { E \bool_if:NT \l__xparse_long_bool { _long } }
- {
- { \exp_not:o \l__xparse_tmpb_tl }
- {
- \prg_replicate:nn { \tl_count:n {#1} }
- { { \c_novalue_tl } }
- }
- }
- \__xparse_prepare_signature:N
- }
-\cs_new_protected:Npn \__xparse_add_expandable_type_E_aux:n #1
- {
- \__xparse_get_grabber:NN #1 \l__xparse_tmpa_tl
- \tl_put_right:Nx \l__xparse_tmpb_tl
- { \exp_not:o \l__xparse_tmpa_tl \exp_not:N #1 }
- }
\cs_new_protected:Npn \__xparse_add_expandable_type_l:w
{ \__xparse_add_expandable_type_u:w ## }
-\cs_new_protected:Npn \__xparse_add_expandable_type_m:w
- {
- \__xparse_add_default:
- \__xparse_add_expandable_grabber:nn
- { m \bool_if:NT \l__xparse_long_bool { _long } } { }
- \__xparse_prepare_signature:N
- }
-\cs_new_protected:Npn \__xparse_add_expandable_type_R:w
- { \__xparse_add_expandable_type_D_aux:NNNn R }
-\cs_new_protected:Npn \__xparse_add_expandable_type_t:w #1
- {
- \__xparse_add_default:
- \__xparse_get_grabber:NN #1 \l__xparse_tmpa_tl
- \__xparse_add_expandable_grabber:nn { t }
- {
- \exp_not:o \l__xparse_tmpa_tl
- \exp_not:N #1
- }
- \__xparse_prepare_signature:N
- }
\cs_new_protected:Npn \__xparse_add_expandable_type_u:w #1
{
\__xparse_add_default:
@@ -1004,227 +116,6 @@
{ \exp_not:c { \l__xparse_expandable_aux_name_tl } }
\__xparse_prepare_signature:N
}
-\cs_new_protected:Npn \__xparse_add_expandable_grabber:nn #1#2
- {
- \tl_put_right:Nx \l__xparse_signature_tl
- { \exp_not:c { __xparse_expandable_grab_ #1 :w } #2 }
- }
-\cs_new_protected:Npn \__xparse_get_grabber:NN #1#2
- {
- \cs_set:Npn \__xparse_tmp:w ##1 #1 {##1}
- \exp_args:Nc \__xparse_get_grabber_auxi:NN
- { __xparse_grabber_ \token_to_str:N #1 :w } #2
- }
-\cs_new_protected:Npn \__xparse_get_grabber_auxi:NN #1#2
- {
- \cs_if_eq:NNTF \__xparse_tmp:w #1
- { \tl_set:Nn #2 {#1} }
- {
- \cs_if_exist:NTF #1
- {
- \int_gincr:N \g__xparse_grabber_int
- \exp_args:Nc \__xparse_get_grabber_auxi:NN
- {
- __xparse_grabber_
- - \int_use:N \g__xparse_grabber_int :w
- }
- #2
- }
- { \__xparse_get_grabber_auxii:NN #1 #2 }
- }
- }
-\cs_new_protected:Npn \__xparse_get_grabber_auxii:NN #1#2
- {
- \cs_set_eq:NN #1 \__xparse_tmp:w
- \tl_set:Nn #2 {#1}
- }
-\cs_new_protected:Npn \__xparse_grab_b:w
- { \__xparse_grab_b_aux:NNw \cs_set_protected_nopar:Npn \tl_trim_spaces:n }
-\cs_new_protected:Npn \__xparse_grab_b_long:w
- { \__xparse_grab_b_aux:NNw \cs_set_protected:Npn \tl_trim_spaces:n }
-\cs_new_protected:Npn \__xparse_grab_b_obey_spaces:w
- { \__xparse_grab_b_aux:NNw \cs_set_protected_nopar:Npn \exp_not:n }
-\cs_new_protected:Npn \__xparse_grab_b_long_obey_spaces:w
- { \__xparse_grab_b_aux:NNw \cs_set_protected:Npn \exp_not:n }
-\cs_new_protected:Npn \__xparse_grab_b_aux:NNw #1#2#3 \__xparse_run_code:
- {
- \__xparse_grab_D_aux:NNnN \begin \end {#3} #1
- \tl_put_left:Nn \l__xparse_signature_tl { \__xparse_grab_b_end:Nw #2 }
- \tl_set_eq:NN \l__xparse_saved_args_tl \l__xparse_args_tl
- \tl_clear:N \l__xparse_args_tl
- \exp_args:Nc \l__xparse_fn_tl { begin ~ }
- }
-\cs_new_protected:Npn \__xparse_grab_b_end:Nw #1#2 \__xparse_run_code:
- {
- \tl_set:Nx \l__xparse_args_tl
- {
- \exp_not:V \l__xparse_saved_args_tl
- { \exp_after:wN #1 \l__xparse_args_tl }
- }
- #2
- \__xparse_run_code:
- \end
- }
-\cs_new_protected:Npn \__xparse_grab_D:w #1#2#3 \__xparse_run_code:
- {
- \__xparse_grab_D_aux:NNnNN #1 #2 {#3} \cs_set_protected_nopar:Npn
- \__xparse_peek_nonspace_remove:NTF
- }
-\cs_new_protected:Npn \__xparse_grab_D_long:w #1#2#3 \__xparse_run_code:
- {
- \__xparse_grab_D_aux:NNnNN #1 #2 {#3} \cs_set_protected:Npn
- \__xparse_peek_nonspace_remove:NTF
- }
-\cs_new_protected:Npn \__xparse_grab_D_obey_spaces:w #1#2#3 \__xparse_run_code:
- {
- \__xparse_grab_D_aux:NNnNN #1 #2 {#3} \cs_set_protected_nopar:Npn
- \__xparse_peek_meaning_remove:NTF
- }
-\cs_new_protected:Npn \__xparse_grab_D_long_obey_spaces:w #1#2#3 \__xparse_run_code:
- {
- \__xparse_grab_D_aux:NNnNN #1 #2 {#3} \cs_set_protected:Npn
- \__xparse_peek_meaning_remove:NTF
- }
-\cs_new_protected:Npn \__xparse_grab_D_aux:NNnNN #1#2#3#4#5
- {
- \__xparse_grab_D_aux:NNnN #1#2 {#3} #4
- #5 #1
- { \__xparse_grab_D_call:Nw #1 }
- { \__xparse_add_arg:o \c_novalue_tl }
- }
-\cs_new_protected:Npn \__xparse_grab_D_aux:NNnN #1#2#3#4
- {
- \tl_set:Nn \l__xparse_signature_tl {#3}
- \exp_after:wN #4 \l__xparse_fn_tl ##1 #2
- {
- \tl_if_in:nnTF {##1} {#1}
- { \__xparse_grab_D_nested:NNnN #1 #2 {##1} #4 }
- {
- \tl_if_blank:oTF { \use_none:n ##1 }
- { \__xparse_add_arg:o { \use_none:n ##1 } }
- {
- \str_if_eq:eeTF
- { \exp_not:o { \use_none:n ##1 } }
- { { \exp_not:o { \use_ii:nnn ##1 \q_nil } } }
- { \__xparse_add_arg:o { \use_ii:nn ##1 } }
- { \__xparse_add_arg:o { \use_none:n ##1 } }
- }
- }
- }
- }
-\tl_new:N \l__xparse_nesting_a_tl
-\tl_new:N \l__xparse_nesting_b_tl
-\quark_new:N \q__xparse
-\cs_new_protected:Npn \__xparse_grab_D_nested:NNnN #1#2#3#4
- {
- \tl_clear:N \l__xparse_nesting_a_tl
- \tl_clear:N \l__xparse_nesting_b_tl
- \exp_after:wN #4 \l__xparse_fn_tl ##1 #1 ##2 \q__xparse ##3 #2
- {
- \tl_put_right:No \l__xparse_nesting_a_tl { \use_none:n ##1 #1 }
- \tl_put_right:No \l__xparse_nesting_b_tl { \use_i:nn #2 ##3 }
- \tl_if_in:nnTF {##2} {#1}
- {
- \l__xparse_fn_tl
- \q_nil ##2 \q__xparse \ERROR
- }
- {
- \tl_put_right:Nx \l__xparse_nesting_a_tl
- { \__xparse_grab_D_nested:w \q_nil ##2 \q_stop }
- \tl_if_in:NnTF \l__xparse_nesting_b_tl {#1}
- {
- \tl_set_eq:NN \l__xparse_tmpa_tl \l__xparse_nesting_b_tl
- \tl_clear:N \l__xparse_nesting_b_tl
- \exp_after:wN \l__xparse_fn_tl \exp_after:wN
- \q_nil \l__xparse_tmpa_tl \q_nil \q__xparse \ERROR
- }
- {
- \tl_put_right:No \l__xparse_nesting_a_tl
- \l__xparse_nesting_b_tl
- \__xparse_add_arg:V \l__xparse_nesting_a_tl
- }
- }
- }
- \l__xparse_fn_tl #3 \q_nil \q__xparse \ERROR
- }
-\cs_new:Npn \__xparse_grab_D_nested:w #1 \q_nil \q_stop
- { \exp_not:o { \use_none:n #1 } }
-\cs_new_protected_nopar:Npn \__xparse_grab_D_call:Nw #1
- {
- \token_if_eq_catcode:NNTF + #1
- {
- \exp_after:wN \exp_after:wN \exp_after:wN
- \l__xparse_fn_tl \char_generate:nn { `#1 } { 11 }
- }
- {
- \__xparse_token_if_cs:NTF #1
- {
- \exp_after:wN \l__xparse_fn_tl
- \cs:w \cs_to_str:N #1 ~ \cs_end:
- }
- {
- \exp_after:wN \l__xparse_fn_tl
- \token_to_str:N #1
- }
- }
- }
-\cs_new_protected:Npn \__xparse_grab_E:w #1#2 \__xparse_run_code:
- {
- \__xparse_grab_E:nnNN {#1} {#2}
- \cs_set_protected_nopar:Npn
- \__xparse_peek_nonspace_remove:NTF
- }
-\cs_new_protected:Npn \__xparse_grab_E_long:w #1#2 \__xparse_run_code:
- {
- \__xparse_grab_E:nnNN {#1} {#2}
- \cs_set_protected:Npn
- \__xparse_peek_nonspace_remove:NTF
- }
-\cs_new_protected:Npn \__xparse_grab_E_obey_spaces:w #1#2 \__xparse_run_code:
- {
- \__xparse_grab_E:nnNN {#1} {#2}
- \cs_set_protected_nopar:Npn
- \__xparse_peek_meaning_remove:NTF
- }
-\cs_new_protected:Npn \__xparse_grab_E_long_obey_spaces:w #1#2 \__xparse_run_code:
- {
- \__xparse_grab_E:nnNN {#1} {#2}
- \cs_set_protected:Npn
- \__xparse_peek_meaning_remove:NTF
- }
-\cs_new_protected:Npn \__xparse_grab_E:nnNN #1#2#3#4
- {
- \exp_after:wN #3 \l__xparse_fn_tl ##1##2##3
- {
- \prop_put:Nnn \l__xparse_tmp_prop {##1} {##3}
- \__xparse_grab_E_loop:NnN #4 { } ##2 \q_recursion_stop
- }
- \prop_clear:N \l__xparse_tmp_prop
- \tl_set:Nn \l__xparse_signature_tl {#2}
- \cs_set_protected:Npn \__xparse_grab_E_finalise:
- {
- \tl_map_inline:nn {#1}
- {
- \prop_get:NnNF \l__xparse_tmp_prop {####1} \l__xparse_tmpb_tl
- { \tl_set_eq:NN \l__xparse_tmpb_tl \c_novalue_tl }
- \tl_put_right:Nx \l__xparse_args_tl
- { { \exp_not:V \l__xparse_tmpb_tl } }
- }
- \l__xparse_signature_tl \__xparse_run_code:
- }
- \__xparse_grab_E_loop:NnN #4 { } #1 \q_recursion_tail \q_recursion_stop
- }
-\cs_new_protected:Npn \__xparse_grab_E_loop:NnN #1#2#3#4 \q_recursion_stop
- {
- \cs_if_eq:NNTF #3 \q_recursion_tail
- { \__xparse_grab_E_finalise: }
- {
- #1 #3
- { \l__xparse_fn_tl #3 {#2#4} }
- { \__xparse_grab_E_loop:NnN #1 {#2#3} #4 \q_recursion_stop }
- }
- }
-\cs_new_protected:Npn \__xparse_grab_E_finalise: { }
\cs_new_protected:Npn \__xparse_grab_G:w #1 \__xparse_run_code:
{
\__xparse_grab_G_aux:nNN {#1} \cs_set_protected_nopar:Npn
@@ -1265,110 +156,6 @@
{ \__xparse_add_arg:n {##1} }
\l__xparse_fn_tl
}
-\cs_new_protected:Npn \__xparse_grab_m:w #1 \__xparse_run_code:
- {
- \tl_set:Nn \l__xparse_signature_tl {#1}
- \exp_after:wN \cs_set_protected_nopar:Npn \l__xparse_fn_tl ##1
- { \__xparse_add_arg:n {##1} }
- \l__xparse_fn_tl
- }
-\cs_new_protected:Npn \__xparse_grab_m_long:w #1 \__xparse_run_code:
- {
- \tl_set:Nn \l__xparse_signature_tl {#1}
- \exp_after:wN \cs_set_protected:Npn \l__xparse_fn_tl ##1
- { \__xparse_add_arg:n {##1} }
- \l__xparse_fn_tl
- }
-\cs_new_protected_nopar:Npn \__xparse_grab_m_aux:Nnnnnnnnn #1#2#3#4#5#6#7#8#9
- {
- \tl_put_right:No \l__xparse_args_tl
- { #1 {#2} {#3} {#4} {#5} {#6} {#7} {#8} {#9} }
- \l__xparse_signature_tl \__xparse_run_code:
- }
-\cs_new_protected:cpn { __xparse_grab_m_1:w } #1 \__xparse_run_code:
- {
- \tl_set:Nn \l__xparse_signature_tl {#1}
- \exp_after:wN \cs_set_eq:NN \l__xparse_fn_tl \__xparse_grab_m_aux:Nnnnnnnnn
- \l__xparse_fn_tl \use_none:nnnnnnn { } { } { } { } { } { } { }
- }
-\cs_new_protected:cpn { __xparse_grab_m_2:w } #1 \__xparse_run_code:
- {
- \tl_set:Nn \l__xparse_signature_tl {#1}
- \exp_after:wN \cs_set_eq:NN \l__xparse_fn_tl \__xparse_grab_m_aux:Nnnnnnnnn
- \l__xparse_fn_tl \use_none:nnnnnn { } { } { } { } { } { }
- }
-\cs_new_protected:cpn { __xparse_grab_m_3:w } #1 \__xparse_run_code:
- {
- \tl_set:Nn \l__xparse_signature_tl {#1}
- \exp_after:wN \cs_set_eq:NN \l__xparse_fn_tl \__xparse_grab_m_aux:Nnnnnnnnn
- \l__xparse_fn_tl \use_none:nnnnn { } { } { } { } { }
- }
-\cs_new_protected:cpn { __xparse_grab_m_4:w } #1 \__xparse_run_code:
- {
- \tl_set:Nn \l__xparse_signature_tl {#1}
- \exp_after:wN \cs_set_eq:NN \l__xparse_fn_tl \__xparse_grab_m_aux:Nnnnnnnnn
- \l__xparse_fn_tl \use_none:nnnn { } { } { } { }
- }
-\cs_new_protected:cpn { __xparse_grab_m_5:w } #1 \__xparse_run_code:
- {
- \tl_set:Nn \l__xparse_signature_tl {#1}
- \exp_after:wN \cs_set_eq:NN \l__xparse_fn_tl \__xparse_grab_m_aux:Nnnnnnnnn
- \l__xparse_fn_tl \use_none:nnn { } { } { }
- }
-\cs_new_protected:cpn { __xparse_grab_m_6:w } #1 \__xparse_run_code:
- {
- \tl_set:Nn \l__xparse_signature_tl {#1}
- \exp_after:wN \cs_set_eq:NN \l__xparse_fn_tl \__xparse_grab_m_aux:Nnnnnnnnn
- \l__xparse_fn_tl \use_none:nn { } { }
- }
-\cs_new_protected:cpn { __xparse_grab_m_7:w } #1 \__xparse_run_code:
- {
- \tl_set:Nn \l__xparse_signature_tl {#1}
- \exp_after:wN \cs_set_eq:NN \l__xparse_fn_tl \__xparse_grab_m_aux:Nnnnnnnnn
- \l__xparse_fn_tl \use_none:n { }
- }
-\cs_new_protected:cpn { __xparse_grab_m_8:w } #1 \__xparse_run_code:
- {
- \tl_set:Nn \l__xparse_signature_tl {#1}
- \exp_after:wN \cs_set_eq:NN \l__xparse_fn_tl \__xparse_grab_m_aux:Nnnnnnnnn
- \l__xparse_fn_tl \prg_do_nothing:
- }
-\cs_new_protected:cpx { __xparse_grab_m_9:w }
- {
- \exp_not:c { __xparse_grab_m_5:w }
- \exp_not:c { __xparse_grab_m_4:w }
- }
-\cs_new_protected:Npn \__xparse_grab_R:w #1#2#3 \__xparse_run_code:
- { \__xparse_grab_R_aux:NNnN #1 #2 {#3} \cs_set_protected_nopar:Npn }
-\cs_new_protected:Npn \__xparse_grab_R_long:w #1#2#3 \__xparse_run_code:
- { \__xparse_grab_R_aux:NNnN #1 #2 {#3} \cs_set_protected:Npn }
-\cs_new_protected:Npn \__xparse_grab_R_aux:NNnN #1#2#3#4
- {
- \__xparse_grab_D_aux:NNnN #1 #2 {#3} #4
- \__xparse_peek_nonspace_remove:NTF #1
- { \__xparse_grab_D_call:Nw #1 }
- {
- \__kernel_msg_error:nnxx { xparse } { missing-required }
- { \__xparse_environment_or_command: }
- { \token_to_str:N #1 }
- \__xparse_add_arg:o \c_novalue_tl
- }
- }
-\cs_new_protected:Npn \__xparse_grab_t:w
- { \__xparse_grab_t_aux:NNw \__xparse_peek_nonspace_remove:NTF }
-\cs_new_protected:Npn \__xparse_grab_t_obey_spaces:w
- { \__xparse_grab_t_aux:NNw \__xparse_peek_meaning_remove:NTF }
-\cs_new_protected:Npn \__xparse_grab_t_aux:NNw #1#2#3 \__xparse_run_code:
- {
- \tl_set:Nn \l__xparse_signature_tl {#3}
- \exp_after:wN \cs_set_protected:Npn \l__xparse_fn_tl
- {
- #1 #2
- { \__xparse_add_arg:n { \BooleanTrue } }
- { \__xparse_add_arg:n { \BooleanFalse } }
- }
- \l__xparse_fn_tl
- }
\cs_new_protected:Npn \__xparse_grab_u:w #1#2 \__xparse_run_code:
{ \__xparse_grab_u_aux:nnN {#1} {#2} \cs_set_protected_nopar:Npn }
\cs_new_protected:Npn \__xparse_grab_u_long:w #1#2 \__xparse_run_code:
@@ -1380,1013 +167,6 @@
{ \__xparse_add_arg:n {##1} }
\l__xparse_fn_tl
}
-\tl_new:N \l__xparse_v_arg_tl
-\cs_new_protected:Npn \__xparse_grab_v:w
- {
- \bool_set_false:N \l__xparse_long_bool
- \__xparse_grab_v_aux:w
- }
-\cs_new_protected:Npn \__xparse_grab_v_long:w
- {
- \bool_set_true:N \l__xparse_long_bool
- \__xparse_grab_v_aux:w
- }
-\cs_new_protected:Npn \__xparse_grab_v_aux:w #1 \__xparse_run_code:
- {
- \tl_set:Nn \l__xparse_signature_tl {#1}
- \group_begin:
- \group_align_safe_begin:
- \tex_escapechar:D = 92 \scan_stop:
- \tl_clear:N \l__xparse_v_arg_tl
- \peek_remove_spaces:n
- {
- \peek_meaning_remove:NTF \c_group_begin_token
- {
- \group_align_safe_end:
- \__xparse_grab_v_bgroup:
- }
- {
- \peek_N_type:TF
- { \__xparse_grab_v_aux_test:N }
- { \__xparse_grab_v_aux_abort:n { } }
- }
- }
- }
-\cs_new_protected:Npn \__xparse_grab_v_group_end:
- {
- \group_align_safe_end:
- \exp_args:NNNo
- \group_end:
- \tl_set:Nn \l__xparse_v_arg_tl { \l__xparse_v_arg_tl }
- }
-\cs_new_protected:Npn \__xparse_grab_v_aux_test:N #1
- {
- \__xparse_grab_v_token_if_char:NTF #1
- {
- \__xparse_grab_v_aux_put:N #1
- \__xparse_grab_v_aux_catcodes:
- \__xparse_grab_v_aux_loop:N #1
- }
- { \__xparse_grab_v_aux_abort:n {#1} #1 }
- }
-\cs_new_protected:Npn \__xparse_grab_v_aux_loop:N #1
- {
- \peek_N_type:TF
- { \__xparse_grab_v_aux_loop:NN #1 }
- { \__xparse_grab_v_aux_abort:n { } }
- }
-\cs_new_protected:Npn \__xparse_grab_v_aux_loop:NN #1#2
- {
- \__xparse_grab_v_token_if_char:NTF #2
- {
- \token_if_eq_charcode:NNTF #1 #2
- { \__xparse_grab_v_aux_loop_end: }
- {
- \__xparse_grab_v_aux_put:N #2
- \__xparse_grab_v_aux_loop:N #1
- }
- }
- { \__xparse_grab_v_aux_abort:n {#2} #2 }
- }
-\cs_new_protected:Npn \__xparse_grab_v_aux_loop_end:
- {
- \__xparse_grab_v_group_end:
- \__xparse_add_arg:x { \tl_tail:N \l__xparse_v_arg_tl }
- }
-\int_new:N \l__xparse_v_nesting_int
-\cs_new_protected:Npx \__xparse_grab_v_bgroup:
- {
- \exp_not:N \__xparse_grab_v_aux_catcodes:
- \exp_not:n { \int_set:Nn \l__xparse_v_nesting_int { 1 } }
- \exp_not:N \__xparse_grab_v_aux_put:N \iow_char:N \{
- \exp_not:N \__xparse_grab_v_bgroup_loop:
- }
-\cs_new_protected:Npn \__xparse_grab_v_bgroup_loop:
- {
- \peek_N_type:TF
- { \__xparse_grab_v_bgroup_loop:N }
- { \__xparse_grab_v_aux_abort:n { } }
- }
-\cs_new_protected:Npn \__xparse_grab_v_bgroup_loop:N #1
- {
- \__xparse_grab_v_token_if_char:NTF #1
- {
- \token_if_eq_charcode:NNTF \c_group_end_token #1
- {
- \int_decr:N \l__xparse_v_nesting_int
- \int_compare:nNnTF \l__xparse_v_nesting_int > 0
- {
- \__xparse_grab_v_aux_put:N #1
- \__xparse_grab_v_bgroup_loop:
- }
- { \__xparse_grab_v_aux_loop_end: }
- }
- {
- \token_if_eq_charcode:NNT \c_group_begin_token #1
- { \int_incr:N \l__xparse_v_nesting_int }
- \__xparse_grab_v_aux_put:N #1
- \__xparse_grab_v_bgroup_loop:
- }
- }
- { \__xparse_grab_v_aux_abort:n {#1} #1 }
- }
-\cs_new_protected:Npn \__xparse_grab_v_aux_catcodes:
- {
- \cs_set_eq:NN \do \char_set_catcode_other:N
- \dospecials
- \tex_endlinechar:D = `\^^M \scan_stop:
- \bool_if:NTF \l__xparse_long_bool
- { \char_set_catcode_other:n { \tex_endlinechar:D } }
- { \char_set_catcode_parameter:n { \tex_endlinechar:D } }
- }
-\cs_new_protected:Npn \__xparse_grab_v_aux_abort:n #1
- {
- \__xparse_grab_v_group_end:
- \exp_after:wN \exp_after:wN \exp_after:wN
- \peek_meaning_remove:NTF \char_generate:nn { \tex_endlinechar:D } { 6 }
- {
- \__kernel_msg_error:nnxxx { xparse } { verbatim-newline }
- { \__xparse_environment_or_command: }
- { \tl_to_str:N \l__xparse_v_arg_tl }
- { \tl_to_str:n {#1} }
- \__xparse_add_arg:o \c_novalue_tl
- }
- {
- \__kernel_msg_error:nnxxx { xparse } { verbatim-tokenized }
- { \__xparse_environment_or_command: }
- { \tl_to_str:N \l__xparse_v_arg_tl }
- { \tl_to_str:n {#1} }
- \__xparse_add_arg:o \c_novalue_tl
- }
- }
-\cs_new_protected:Npn \__xparse_grab_v_aux_put:N #1
- {
- \tl_put_right:Nx \l__xparse_v_arg_tl
- {
- \token_if_active:NTF #1
- { \exp_not:N #1 } { \token_to_str:N #1 }
- }
- }
-\cs_new_protected:Npn \__xparse_grab_v_token_if_char:NTF #1
- { \str_if_eq:eeTF { } { \str_tail:n {#1} } }
-\cs_new_protected:Npn \__xparse_add_arg:n #1
- {
- \tl_put_right:Nn \l__xparse_args_tl { {#1} }
- \l__xparse_signature_tl \__xparse_run_code:
- }
-\cs_generate_variant:Nn \__xparse_add_arg:n { V , o , x }
-\cs_new:Npn \__xparse_expandable_grab_D:w #1 \q__xparse #2#3
- { #2 { \__xparse_expandable_grab_D:NNNwNNn #1 \q__xparse #2 #3 } }
-\cs_set_protected:Npn \__xparse_tmp:w #1
- {
- \cs_new:Npn \__xparse_expandable_grab_D:NNNwNNn ##1##2##3##4 \q__xparse ##5##6##7
- {
- \str_if_eq:nnTF {##2} {##7}
- {
- \str_if_eq:onTF
- { ##1 { } { } ##7 ##2 \q__xparse ##3 }
- { { } {##2} { } }
- }
- { \use_ii:nn }
- {
- ##1
- { \__xparse_expandable_grab_D:NNNwNNnnn ##1##2##3##4 \q__xparse ##5##6 }
- \q_nil { } ##2 \ERROR \q__xparse \ERROR
- }
- { ##4 {#1} \q__xparse ##5 ##6 {##7} }
- }
- }
-\exp_args:No \__xparse_tmp:w { \c_novalue_tl }
-\cs_new:Npn \__xparse_expandable_grab_D:NNNwNNnnn #1#2#3#4 \q__xparse #5#6#7#8#9
- {
- \exp_args:Nof \__xparse_expandable_grab_D:nnNNNwNN
- { \use_ii:nn #7 #2 }
- { \__xparse_expandable_grab_D:Nw #3 \exp_stop_f: #8 #9 }
- #1#2#3 #4 \q__xparse #5 #6
- }
-\cs_new:Npn \__xparse_expandable_grab_D:Nw #1#2 \ERROR \ERROR { #2 #1 }
-\cs_new:Npn \__xparse_expandable_grab_D:nnNNNwNN #1#2#3#4#5#6 \q__xparse #7#8
- {
- \exp_args:No \tl_if_empty:oTF
- { #3 { \use_none:nnn } #2 \q__xparse #5 #4 \q__xparse #5 }
- {
- \tl_if_blank:oTF { \use_none:nn #1#2 }
- { \__xparse_put_arg_expandable:ow { \use_none:nn #1#2 } }
- {
- \str_if_eq:eeTF
- { \exp_not:o { \use_none:nn #1#2 } }
- { { \exp_not:o { \use_iii:nnnn #1#2 \q_nil } } }
- { \__xparse_put_arg_expandable:ow { \use_iii:nnn #1#2 } }
- { \__xparse_put_arg_expandable:ow { \use_none:nn #1#2 } }
- }
- #6 \q__xparse #7 #8
- }
- {
- #3
- { \__xparse_expandable_grab_D:NNNwNNnnn #3#4#5#6 \q__xparse #7 #8 }
- \q_nil {#1} #2 \ERROR \q__xparse \ERROR
- }
- }
-\cs_new:Npn \__xparse_expandable_grab_D_alt:w #1 \q__xparse #2#3
- { #2 { \__xparse_expandable_grab_D_alt:NNwNNn #1 \q__xparse #2 #3 } }
-\cs_set_protected:Npn \__xparse_tmp:w #1
- {
- \cs_new:Npn \__xparse_expandable_grab_D_alt:NNwNNn ##1##2##3 \q__xparse ##4##5##6
- {
- \str_if_eq:nnTF {##6} {##2}
- {
- \str_if_eq:onTF
- { ##1 { } ##6 ##2 ##2 }
- { { } ##2 }
- }
- { \use_ii:nn }
- {
- ##1
- { \__xparse_expandable_grab_D_alt:NNwn ##4 ##5 ##3 \q__xparse }
- ##6 \ERROR
- }
- { ##3 {#1} \q__xparse ##4 ##5 {##6} }
- }
- }
-\exp_args:No \__xparse_tmp:w { \c_novalue_tl }
-\cs_new:Npn \__xparse_expandable_grab_D_alt:NNwn #1#2#3 \q__xparse #4
- {
- \tl_if_blank:oTF { \use_none:n #4 }
- { \__xparse_put_arg_expandable:ow { \use_none:n #4 } }
- {
- \str_if_eq:eeTF
- { \exp_not:o { \use_none:n #4 } }
- { { \exp_not:o { \use_ii:nnn #4 \q_nil } } }
- { \__xparse_put_arg_expandable:ow { \use_ii:nn #4 } }
- { \__xparse_put_arg_expandable:ow { \use_none:n #4 } }
- }
- #3 \q__xparse #1 #2
- }
-\cs_new:Npn \__xparse_expandable_grab_E:w #1 \q__xparse #2#3
- { \__xparse_expandable_grab_E_aux:w #1 \q__xparse #2 #3 #3 }
-\cs_new:Npn \__xparse_expandable_grab_E_long:w #1 \q__xparse #2#3
- { \__xparse_expandable_grab_E_aux:w #1 \q__xparse #2 #3 #2 }
-\cs_new:Npn \__xparse_expandable_grab_E_aux:w #1 \q__xparse #2#3#4
- { #2 { \__xparse_expandable_grab_E_test:nnw #1 \q__xparse #2 #3 #4 } }
-\cs_new:Npn \__xparse_expandable_grab_E_test:nnw #1#2#3 \q__xparse #4#5#6#7
- {
- \__xparse_expandable_grab_E_loop:nnnNNw {#7} { } { }
- #1 \q_nil \q_nil \q_nil \q_mark #2 \q_nil
- #3 \q__xparse #4 #5 #6
- }
-\cs_new:Npn \__xparse_expandable_grab_E_loop:nnnNNw
- #1#2#3#4#5#6 \q_nil #7 \q_mark #8
- {
- \quark_if_nil:NTF #4
- { \__xparse_expandable_grab_E_end:nnw {#1} {#3} }
- {
- \tl_if_novalue:nTF {#8}
- { \str_if_eq:onTF { #4 { } #1 #5 } {#5} }
- { \use_ii:nn }
- { \__xparse_expandable_grab_E_find:w { #2 #4 #5 #6 } {#3} ~ }
- {
- \__xparse_expandable_grab_E_loop:nnnNNw
- {#1} { #2 #4 #5 } { #3 {#8} }
- #6 \q_nil #7 \q_mark
- }
- }
- }
-\cs_new:Npn \__xparse_expandable_grab_E_find:w #1 \q__xparse #2#3#4
- { #4 { \__xparse_expandable_grab_E_find:nnw #1 \q__xparse #2 #3 #4 } }
-\cs_new:Npn \__xparse_expandable_grab_E_find:nnw #1#2#3 \q_nil #4 \q__xparse #5#6#7#8
- { \__xparse_expandable_grab_E_aux:w {#1} { #2 {#8} #3 } #4 \q__xparse #5 #6 #7 }
-\cs_new:Npn \__xparse_expandable_grab_E_end:nnw #1#2#3 \q__xparse #4#5#6
- { #3 #2 \q__xparse #4 #5 {#1} }
-\cs_new:Npn \__xparse_expandable_grab_m:w #1 \q__xparse #2#3
- { #3 { \__xparse_expandable_grab_m_aux:wNn #1 \q__xparse #2 #3 } }
-\cs_new:Npn \__xparse_expandable_grab_m_long:w #1 \q__xparse #2#3
- { #2 { \__xparse_expandable_grab_m_aux:wNn #1 \q__xparse #2 #3 } }
-\cs_new:Npn \__xparse_expandable_grab_m_aux:wNn #1 \q__xparse #2#3#4
- { #1 {#4} \q__xparse #2 #3 }
-\cs_new:Npn \__xparse_expandable_grab_R:w #1 \q__xparse #2#3
- { #2 { \__xparse_expandable_grab_R_aux:NNNwNNn #1 \q__xparse #2#3 } }
-\cs_set_protected:Npn \__xparse_tmp:w #1
- {
- \cs_new:Npn \__xparse_expandable_grab_R_aux:NNNwNNn ##1##2##3##4 \q__xparse ##5##6##7
- {
- \str_if_eq:nnTF {##7} {##2}
- {
- \str_if_eq:onTF
- { ##1 { } { } ##7 ##2 \q__xparse ##3 }
- { { } {##2} { } }
- }
- { \use_ii:nn }
- {
- ##1
- { \__xparse_expandable_grab_D:NNNwNNnnn ##1##2##3##4 \q__xparse ##5##6 }
- \q_nil { } ##2 \ERROR \q__xparse \ERROR
- }
- {
- \__kernel_msg_expandable_error:nnff
- { xparse } { missing-required }
- { \exp_args:Nf \tl_trim_spaces:n { \token_to_str:N ##5 } }
- { \tl_to_str:n {##2} }
- ##4 {#1} \q__xparse ##5 ##6 {##7}
- }
- }
- }
-\exp_args:No \__xparse_tmp:w { \c_novalue_tl }
-\cs_new:Npn \__xparse_expandable_grab_R_alt:w #1 \q__xparse #2#3
- { #2 { \__xparse_expandable_grab_R_alt_aux:NNwNNn #1 \q__xparse #2#3 } }
-\cs_set_protected:Npn \__xparse_tmp:w #1
- {
- \cs_new:Npn \__xparse_expandable_grab_R_alt_aux:NNwNNn ##1##2##3 \q__xparse ##4##5##6
- {
- \str_if_eq:nnTF {##6} {##2}
- {
- \str_if_eq:onTF
- { ##1 { } ##6 ##2 ##2 }
- { { } ##2 }
- }
- { \use_ii:nn }
- {
- ##1
- { \__xparse_expandable_grab_D_alt:NNwn ##4 ##5 ##3 \q__xparse }
- ##6 \ERROR
- }
- {
- \__kernel_msg_expandable_error:nnff
- { xparse } { missing-required }
- { \exp_args:Nf \tl_trim_spaces:n { \token_to_str:N ##4 } }
- { \tl_to_str:n {##2} }
- ##3 {#1} \q__xparse ##4 ##5 {##6}
- }
- }
- }
-\exp_args:No \__xparse_tmp:w { \c_novalue_tl }
-\cs_new:Npn \__xparse_expandable_grab_t:w #1 \q__xparse #2#3
- { #2 { \__xparse_expandable_grab_t_aux:NNwn #1 \q__xparse #2 #3 } }
-\cs_new:Npn \__xparse_expandable_grab_t_aux:NNwn #1#2#3 \q__xparse #4#5#6
- {
- \str_if_eq:onTF { #1 { } #6 #2 } {#2}
- { #3 { \BooleanTrue } \q__xparse #4 #5 }
- { #3 { \BooleanFalse } \q__xparse #4 #5 {#6} }
- }
-\cs_new_eq:NN \__xparse_expandable_grab_u:w \prg_do_nothing:
-\cs_new:Npn \__xparse_put_arg_expandable:nw #1#2 \q__xparse { #2 {#1} \q__xparse }
-\cs_generate_variant:Nn \__xparse_put_arg_expandable:nw { o }
-\cs_new_protected:Npn \__xparse_bool_reverse:N #1
- {
- \bool_if:NTF #1
- { \tl_set:Nn \ProcessedArgument { \c_false_bool } }
- { \tl_set:Nn \ProcessedArgument { \c_true_bool } }
- }
-\seq_new:N \l__xparse_split_list_seq
-\tl_new:N \l__xparse_split_list_tl
-\cs_new_protected:Npn \__xparse_split_list:nn #1#2
- {
- \tl_if_single:nTF {#1}
- {
- \token_if_cs:NTF #1
- { \__xparse_split_list_multi:nn {#1} {#2} }
- { \__xparse_split_list_single:Nn #1 {#2} }
- }
- { \__xparse_split_list_multi:nn {#1} {#2} }
- }
-\cs_new_protected:Npn \__xparse_split_list_multi:nn #1#2
- {
- \seq_set_split:Nnn \l__xparse_split_list_seq {#1} {#2}
- \tl_clear:N \ProcessedArgument
- \seq_map_inline:Nn \l__xparse_split_list_seq
- { \tl_put_right:Nn \ProcessedArgument { {##1} } }
- }
-\cs_generate_variant:Nn \__xparse_split_list_multi:nn { nV }
-\group_begin:
-\char_set_catcode_active:N \^^@
-\cs_new_protected:Npn \__xparse_split_list_single:Nn #1#2
- {
- \tl_set:Nn \l__xparse_split_list_tl {#2}
- \group_begin:
- \char_set_lccode:nn { `\^^@ } { `#1 }
- \tex_lowercase:D
- {
- \group_end:
- \tl_replace_all:Nnn \l__xparse_split_list_tl { ^^@ }
- } {#1}
- \__xparse_split_list_multi:nV {#1} \l__xparse_split_list_tl
- }
-\group_end:
-\cs_new_protected:Npn \__xparse_split_argument:nnn #1#2#3
- {
- \__xparse_split_list:nn {#2} {#3}
- \exp_args:Nf \__xparse_split_argument_aux:nnnn
- { \tl_count:N \ProcessedArgument }
- {#1} {#2} {#3}
- }
-\cs_new_protected:Npn \__xparse_split_argument_aux:nnnn #1#2#3#4
- {
- \int_compare:nNnF {#1} = { #2 + 1 }
- {
- \int_compare:nNnTF {#1} > { #2 + 1 }
- {
- \tl_set:Nx \ProcessedArgument
- {
- \exp_last_unbraced:NnNo
- \__xparse_split_argument_aux:n
- { #2 + 1 }
- \use_none_delimit_by_q_stop:w
- \ProcessedArgument
- \q_stop
- }
- \__kernel_msg_error:nnxxx { xparse } { split-excess-tokens }
- { \tl_to_str:n {#3} } { \int_eval:n { #2 + 1 } }
- { \tl_to_str:n {#4} }
- }
- {
- \tl_put_right:Nx \ProcessedArgument
- {
- \prg_replicate:nn { #2 + 1 - (#1) }
- { { \exp_not:V \c_novalue_tl } }
- }
- }
- }
- }
-\cs_new:Npn \__xparse_split_argument_aux:n #1
- { \prg_replicate:nn {#1} { \__xparse_split_argument_aux:wn } }
-\cs_new:Npn \__xparse_split_argument_aux:wn #1 \use_none_delimit_by_q_stop:w #2
- {
- \exp_not:n { {#2} }
- #1
- \use_none_delimit_by_q_stop:w
- }
-\cs_new_protected:Npn \__xparse_trim_spaces:n #1
- { \tl_set:Nx \ProcessedArgument { \tl_trim_spaces:n {#1} } }
-\cs_new_protected:Npn \__xparse_get_arg_spec_error:N #1
- {
- \bool_set_false:N \l__xparse_environment_bool
- \tl_set:Nn \l__xparse_fn_tl {#1}
- \__xparse_get_arg_spec_error_aux:n { \cs_if_exist:NTF #1 }
- }
-\cs_new_protected:Npn \__xparse_get_arg_spec_error:n #1
- {
- \bool_set_true:N \l__xparse_environment_bool
- \str_set:Nx \l__xparse_environment_str {#1}
- \__xparse_get_arg_spec_error_aux:n
- { \cs_if_exist:cTF { \l__xparse_environment_str } }
- }
-\cs_new_protected:Npn \__xparse_get_arg_spec_error_aux:n #1
- {
- #1
- {
- \__kernel_msg_error:nnx { xparse } { non-xparse }
- { \__xparse_environment_or_command: }
- }
- {
- \__kernel_msg_error:nnx { xparse } { unknown }
- { \__xparse_environment_or_command: }
- }
- }
-\cs_new_protected:Npn \__xparse_get_arg_spec:NTF #1#2#3
- {
- \__xparse_cmd_if_xparse:NTF #1
- {
- \tl_set:Nx \ArgumentSpecification { \tl_item:Nn #1 { 2 } }
- #2
- }
- {#3}
- }
-\cs_new_protected:Npn \__xparse_get_arg_spec:N #1
- {
- \__xparse_get_arg_spec:NTF #1 { }
- { \__xparse_get_arg_spec_error:N #1 }
- }
-\cs_new_protected:Npn \__xparse_get_arg_spec:n #1
- {
- \exp_args:Nc \__xparse_get_arg_spec:NTF
- { environment~ \tl_to_str:n {#1} }
- { }
- { \__xparse_get_arg_spec_error:n {#1} }
- }
-\tl_new:N \ArgumentSpecification
-\cs_new_protected:Npn \__xparse_show_arg_spec:N #1
- {
- \__xparse_get_arg_spec:NTF #1
- { \tl_show:N \ArgumentSpecification }
- { \__xparse_get_arg_spec_error:N #1 }
- }
-\cs_new_protected:Npn \__xparse_show_arg_spec:n #1
- {
- \exp_args:Nc \__xparse_get_arg_spec:NTF
- { environment~ \tl_to_str:n {#1} }
- { \tl_show:N \ArgumentSpecification }
- { \__xparse_get_arg_spec_error:n {#1} }
- }
-\cs_new_protected:Npn \__xparse_check_definable:nNT #1
- { \tl_trim_spaces_apply:nN {#1} \__xparse_check_definable_aux:nN }
-\group_begin:
- \char_set_catcode_active:n { `? }
- \cs_new_protected:Npn \__xparse_check_definable_aux:nN #1#2
- {
- \group_begin:
- \tl_if_single_token:nTF {#1}
- {
- \int_set:Nn \tex_escapechar:D { 92 }
- \exp_args:Nx \tl_if_empty:nTF
- { \exp_args:No \str_tail:n { \token_to_str:N #1 } }
- {
- \exp_args:Nx \char_set_lccode:nn
- { ` \str_head:n {#1} } { `? }
- \tex_lowercase:D { \tl_if_eq:nnTF {#1} } { ? }
- { \group_end: \use_iii:nnn }
- { \group_end: \use_i:nnn }
- }
- { \group_end: \use_iii:nnn }
- }
- { \group_end: \use_ii:nnn }
- {
- \__kernel_msg_error:nnxx { xparse } { not-definable }
- { \tl_to_str:n {#1} } { \token_to_str:N #2 }
- }
- {
- \__kernel_msg_error:nnxx { xparse } { not-one-token }
- { \tl_to_str:n {#1} } { \token_to_str:N #2 }
- }
- }
-\group_end:
-\cs_new_protected:Npn \__xparse_token_if_cs:NTF #1
- {
- \group_begin:
- \int_set:Nn \tex_escapechar:D { 92 }
- \exp_args:Nx \tl_if_empty:nTF
- { \exp_args:No \str_tail:n { \token_to_str:N #1 } }
- { \group_end: \use_ii:nn }
- { \group_end: \use_i:nn }
- }
-\cs_new:Npn \__xparse_tl_mapthread_function:NNN #1#2#3
- {
- \exp_after:wN \exp_after:wN
- \exp_after:wN \__xparse_tl_mapthread_loop:w
- \exp_after:wN \exp_after:wN
- \exp_after:wN #3
- \exp_after:wN #1
- \exp_after:wN \q_recursion_tail
- \exp_after:wN \q_mark
- #2
- \q_recursion_tail
- \q_recursion_stop
- }
-\cs_new:Npn \__xparse_tl_mapthread_function:nnN #1#2#3
- {
- \__xparse_tl_mapthread_loop:w #3
- #1 \q_recursion_tail \q_mark
- #2 \q_recursion_tail \q_recursion_stop
- }
-\cs_new:Npn \__xparse_tl_mapthread_loop:w #1#2#3 \q_mark #4
- {
- \quark_if_recursion_tail_stop:n {#2}
- \quark_if_recursion_tail_stop:n {#4}
- #1 {#2} {#4}
- \__xparse_tl_mapthread_loop:w #1#3 \q_mark
- }
-\cs_new_protected:Npn \__xparse_cmd_if_xparse:NTF #1
- {
- \exp_args:Nf \str_case_e:nnTF
- {
- \exp_args:Nf \tl_if_empty:nT { \cs_argument_spec:N #1 }
- {
- \exp_last_unbraced:Nf \__xparse_cmd_if_xparse_aux:w
- { \cs_replacement_spec:N #1 } ~ \q_stop
- }
- }
- {
- { \token_to_str:N \__xparse_start:nNNnnn } { }
- { \token_to_str:N \__xparse_start_expandable:nNNNNn } { }
- { \token_to_str:N \__xparse_start_env:nnnnn } { }
- }
- }
-\cs_new:Npn \__xparse_cmd_if_xparse_aux:w #1 ~ #2 \q_stop {#1}
-\cs_new_protected:Npn \__xparse_peek_nonspace:NTF
- { \__xparse_peek_nonspace_aux:nNNTF { } \__xparse_peek_meaning:NTF }
-\cs_new_protected:Npn \__xparse_peek_nonspace_remove:NTF
- { \__xparse_peek_nonspace_aux:nNNTF { } \__xparse_peek_meaning_remove:NTF }
-\cs_new_protected:Npn \__xparse_peek_nonspace_aux:nNNTF #1#2#3#4#5
- {
- \peek_meaning_remove:NTF \c_space_token
- { \__xparse_peek_nonspace_aux:nNNTF { #1 ~ } #2 #3 {#4} {#5} }
- { #2 #3 { #4 } { #5 #1 } }
- }
-\cs_new_protected:Npn \__xparse_peek_meaning:NTF
- { \__xparse_peek_meaning_aux:NNTF \c_false_bool }
-\cs_new_protected:Npn \__xparse_peek_meaning_remove:NTF
- { \__xparse_peek_meaning_aux:NNTF \c_true_bool }
-\cs_new_protected:Npn \__xparse_peek_meaning_aux:NNTF #1#2#3#4
- {
- \tl_set:Nn \l__xparse_tmpa_tl {#3}
- \tl_set:Nn \l__xparse_tmpb_tl {#4}
- \peek_meaning:NTF #2
- {
- \token_if_eq_meaning:NNTF #2 \c_group_begin_token
- { \__xparse_peek_true_remove:Nw #1 }
- {
- \__xparse_token_if_cs:NTF #2
- { \__xparse_peek_cs_check_equal:NNN #1 #2 }
- { \__xparse_peek_true_remove:Nw #1 }
- }
- }
- { \l__xparse_tmpb_tl }
- }
-\cs_new_protected:Npn \__xparse_peek_cs_check_equal:NNN #1#2#3
- {
- \str_if_eq:nnTF {#2} {#3}
- { \__xparse_peek_true_remove:Nw #1 }
- { \l__xparse_tmpb_tl }
- #3
- }
-\cs_new_protected:Npn \__xparse_peek_true_remove:Nw #1
- {
- \bool_if:NTF #1
- {
- \tex_afterassignment:D \l__xparse_tmpa_tl
- \cs_set_eq:NN \__xparse_tmp:w
- }
- { \l__xparse_tmpa_tl }
- }
-\cs_new:Npn \__xparse_environment_or_command:
- {
- \bool_if:NTF \l__xparse_environment_bool
- { environment ~ ' \l__xparse_environment_str ' }
- {
- command ~ '
- \exp_args:Nf \tl_trim_spaces:n
- { \exp_after:wN \token_to_str:N \l__xparse_fn_tl }
- '
- }
- }
-\tl_const:Nn \c__xparse_ignore_def_tl
- { \\ \\ LaTeX~will~ignore~this~entire~definition. }
-\__kernel_msg_new:nnnn { xparse } { arg-after-body }
- { In~the~definition~of~#1,~b~(body)~argument~must~be~last. }
- {
- The~'body'~argument~type~is~followed~by~'#2'~in~the~argument~
- specification~of~the~#1.~This~is~not~allowed.
- \c__xparse_ignore_def_tl
- }
-\__kernel_msg_new:nnnn { xparse } { bad-arg-spec }
- { Bad~argument~specification~'#2'~for~#1. }
- {
- The~argument~specification~provided~was~not~valid:~
- one~or~more~mandatory~pieces~of~information~were~missing.
- \c__xparse_ignore_def_tl
- }
-\__kernel_msg_new:nnnn { xparse } { command-already-defined }
- { Command~'#1'~already~defined! }
- {
- You~have~used~#2~
- with~a~command~that~already~has~a~definition. \\ \\
- The~existing~definition~of~'#1'~will~not~be~altered.
- }
-\__kernel_msg_new:nnnn { xparse } { command-not-yet-defined }
- { Command ~'#1'~not~yet~defined! }
- {
- You~have~used~#2~
- with~a~command~that~was~never~defined.
- \c__xparse_ignore_def_tl
- }
-\__kernel_msg_new:nnnn { xparse } { environment-already-defined }
- { Environment~'#1'~already~defined! }
- {
- You~have~used~\NewDocumentEnvironment
- with~an~environment~that~already~has~a~definition. \\ \\
- The~existing~definition~of~'#1'~will~not~be~altered.
- }
-\__kernel_msg_new:nnnn { xparse } { environment-not-yet-defined }
- { Environment~'#1'~not~yet~defined! }
- {
- You~have~used~\RenewDocumentEnvironment
- with~an~environment~that~was~never~defined.
- \c__xparse_ignore_def_tl
- }
-\__kernel_msg_new:nnnn { xparse } { expandable-ending-optional }
- {
- Argument~specification~'#2'~for~expandable~command~'#1'~
- ends~with~optional~argument.
- }
- {
- Expandable~commands~must~have~a~final~mandatory~argument~
- (or~no~arguments~at~all).~You~cannot~have~a~terminal~optional~
- argument~with~expandable~commands.
- }
-\__kernel_msg_new:nnnn { xparse } { inconsistent-long }
- { Inconsistent~long~arguments~for~expandable~command~'#1'. }
- {
- The~arguments~for~an~expandable~command~must~not~involve~short~
- arguments~after~long~arguments.~You~have~tried~to~mix~the~two~types.
- }
-\__kernel_msg_new:nnnn { xparse } { invalid-command-arg }
- { Argument~type~'#2'~not~available~for~#1. }
- {
- The~letter~'#2'~can~only~be~used~in~environment~argument~
- specifications,~not~for~commands.
- \\ \\
- LaTeX~will~ignore~this~entire~definition.
- }
-\__kernel_msg_new:nnnn { xparse } { invalid-expandable-argument-type }
- { Argument~type~'#2'~not~available~for~expandable~command~'#1'. }
- {
- The~letter~'#2'~specifies~an~argument~type~which~cannot~be~used~
- in~an~expandable~command.
- \c__xparse_ignore_def_tl
- }
-\__kernel_msg_new:nnnn { xparse } { invalid-after-optional-expandably }
- {
- Argument~type~'#2'~not~available~after~optional~argument~
- for~expandable~command~'#1'.
- }
- {
- The~letter~'#2'~specifies~an~argument~type~which~cannot~be~used~
- in~an~expandable~command~after~an~optional~argument.
- \c__xparse_ignore_def_tl
- }
-\__kernel_msg_new:nnnn { xparse } { non-trailing-obey-spaces }
- { Prefix~'!'~used~before~mandatory~argument~'#2'~of~#1. }
- {
- The~prefix~'!'~can~only~apply~to~trailing~optional~arguments.
- \c__xparse_ignore_def_tl
- }
-\__kernel_msg_new:nnnn { xparse } { not-definable }
- { First~argument~of~'#2'~must~be~a~command. }
- {
- The~first~argument~of~'#2'~should~be~the~document~command~that~will~
- be~defined.~The~provided~argument~'#1'~is~a~character.~Perhaps~a~
- backslash~is~missing?
- \c__xparse_ignore_def_tl
- }
-\__kernel_msg_new:nnnn { xparse } { not-one-token }
- { First~argument~of~'#2'~must~be~a~command. }
- {
- The~first~argument~of~'#2'~should~be~the~document~command~that~will~
- be~defined.~The~provided~argument~'#1'~contains~more~than~one~
- token.~Perhaps~a~backslash~is~missing?
- \c__xparse_ignore_def_tl
- }
-\__kernel_msg_new:nnnn { xparse } { not-single-token }
- {
- Argument~delimiter~'#2'~for~the~#1~should~be~
- a~single~non-space~token.
- }
- {
- The~argument~specification~provided~was~not~valid:~in~a~place~
- where~a~single~token~is~required,~LaTeX~found~'#2'.
- \c__xparse_ignore_def_tl
- }
-\__kernel_msg_new:nnnn { xparse } { forbidden-implicit-group-token }
- { Argument~delimiter~'#2'~for~the~#1~is~not~allowed. }
- {
- The~argument~specification~provided~was~not~valid:~the~implicit~
- #3-group~token~'#2'~is~not~allowed~as~an~argument~delimiter.
- \c__xparse_ignore_def_tl
- }
-\__kernel_msg_new:nnnn { xparse } { processor-in-expandable }
- { Argument~processor~'>{#2}'~cannot~be~used~for~the~expandable~command~'#1'. }
- {
- The~argument~specification~for~#1~contains~a~processor~function:~
- this~is~only~supported~for~standard~robust~commands.
- \c__xparse_ignore_def_tl
- }
-\__kernel_msg_new:nnnn { xparse } { too-many-arguments }
- { Too~many~arguments~in~argument~specification~'#2'~of~#1. }
- {
- The~argument~specification~provided~has~more~than~9~arguments.~
- This~cannot~be~implemented.
- \c__xparse_ignore_def_tl
- }
-\__kernel_msg_new:nnnn { xparse } { two-markers }
- { Two~'#2'~apply~to~the~same~argument~in~argument~specification~of~#1. }
- {
- The~argument~specification~provided~has~two~markers~'#2'~applying~
- to~the~same~argument;~these~are~redundant.
- }
-\__kernel_msg_new:nnnn { xparse } { unknown-argument-type }
- { Unknown~argument~type~'#2'~for~the~#1. }
- {
- The~letter~'#2'~does~not~specify~a~known~argument~type.
- \c__xparse_ignore_def_tl
- }
-\__kernel_msg_new:nnn { xparse } { if-boolean }
- { Invalid~use~\iow_char:N\\IfBooleanTF~{#1} }
-\__kernel_msg_new:nnnn { xparse } { loop-in-defaults }
- { Defaults~of~#1~have~circular~dependency. }
- {
- The~default~values~of~two~or~more~arguments~of~the~#1~
- depend~on~each~other~in~a~way~that~cannot~be~resolved.
- }
-\__kernel_msg_new:nnnn { xparse } { missing-required }
- { Missing~required~argument~for~#1. }
- {
- The~current~#1~expects~an~argument~starting~with~'#2'.~
- LaTeX~did~not~find~it,~and~will~insert~a~default~value~to~be~processed.
- }
-\__kernel_msg_new:nnnn { xparse } { non-xparse }
- { \str_uppercase:n #1~not~defined~using~xparse. }
- {
- You~have~asked~for~the~argument~specification~for~the~#1,~
- but~this~was~not~defined~using~xparse.
- }
-\__kernel_msg_new:nnnn { xparse } { split-excess-tokens }
- { Too~many~'#1'~tokens~when~trying~to~split~argument. }
- {
- LaTeX~was~asked~to~split~the~input~'#3'~
- at~each~occurrence~of~the~token~'#1',~up~to~a~maximum~of~#2~parts.~
- There~were~too~many~'#1'~tokens.
- }
-\__kernel_msg_new:nnnn { xparse } { unknown }
- { Unknown~document~#1. }
- {
- You~have~asked~for~the~argument~specification~for~the~#1,~
- but~it~is~not~defined.
- }
-\__kernel_msg_new:nnnn { xparse } { verbatim-newline }
- { Verbatim~argument~of~#1~ended~by~end~of~line. }
- {
- The~verbatim~argument~of~the~#1~cannot~contain~more~than~one~line,~
- but~the~end~
- of~the~current~line~has~been~reached.~You~may~have~forgotten~the~
- closing~delimiter.
- \\ \\
- LaTeX~will~ignore~'#2'.
- }
-\__kernel_msg_new:nnnn { xparse } { verbatim-tokenized }
- { The~verbatim~#1~cannot~be~used~inside~an~argument. }
- {
- The~#1~takes~a~verbatim~argument.~
- It~may~not~appear~within~the~argument~of~another~function.~
- It~received~an~illegal~token \tl_if_empty:nF {#3} { ~'#3' } .
- \\ \\
- LaTeX~will~ignore~'#2'.
- }
-\__kernel_msg_new:nnn { xparse } { define-command }
- {
- Defining~command~#1~
- with~sig.~'#2'~\msg_line_context:.
- }
-\__kernel_msg_new:nnn { xparse } { define-environment }
- {
- Defining~environment~'#1'~
- with~sig.~'#2'~\msg_line_context:.
- }
-\__kernel_msg_new:nnn { xparse } { redefine-command }
- {
- Redefining~command~#1~
- with~sig.~'#2'~\msg_line_context:.
- }
-\__kernel_msg_new:nnn { xparse } { redefine-environment }
- {
- Redefining~environment~'#1'~
- with~sig.~'#2'~\msg_line_context:.
- }
-\__kernel_msg_new:nnn { xparse } { optional-mandatory }
- {
- Since~the~mandatory~argument~'#1'~has~the~same~delimiter~'#2'~
- as~a~previous~optional~argument,~it~will~not~be~possible~to~
- omit~all~optional~arguments~when~calling~this~command.
- }
-\__kernel_msg_new:nnn { xparse } { unsupported-let }
- {
- The~command~'#1'~was~undefined~but~not~the~associated~commands~
- '#1~code'~and/or~'#1~defaults'.~Maybe~you~tried~using~
- \iow_char:N\\let.~This~may~lead~to~an~infinite~loop.
- }
-\cs_new_eq:NN \BooleanFalse \c_false_bool
-\cs_new_eq:NN \BooleanTrue \c_true_bool
-\cs_new_protected:Npn \NewDocumentCommand #1#2#3
- {
- \__xparse_check_definable:nNT {#1} \NewDocumentCommand
- {
- \cs_if_exist:NTF #1
- {
- \__kernel_msg_error:nnxx { xparse } { command-already-defined }
- { \use:nnn \token_to_str:N #1 { } }
- { \token_to_str:N \NewDocumentCommand }
- }
- { \__xparse_declare_cmd:Nnn #1 {#2} {#3} }
- }
- }
-\cs_new_protected:Npn \RenewDocumentCommand #1#2#3
- {
- \__xparse_check_definable:nNT {#1} \RenewDocumentCommand
- {
- \cs_if_exist:NTF #1
- { \__xparse_declare_cmd:Nnn #1 {#2} {#3} }
- {
- \__kernel_msg_error:nnxx { xparse } { command-not-yet-defined }
- { \use:nnn \token_to_str:N #1 { } }
- { \token_to_str:N \RenewDocumentCommand }
- }
- }
- }
-\cs_new_protected:Npn \ProvideDocumentCommand #1#2#3
- {
- \__xparse_check_definable:nNT {#1} \ProvideDocumentCommand
- { \cs_if_exist:NF #1 { \__xparse_declare_cmd:Nnn #1 {#2} {#3} } }
- }
-\cs_new_protected:Npn \DeclareDocumentCommand #1#2#3
- {
- \__xparse_check_definable:nNT {#1} \DeclareDocumentCommand
- { \__xparse_declare_cmd:Nnn #1 {#2} {#3} }
- }
-\cs_new_protected:Npn \NewDocumentEnvironment #1#2#3#4
- {
- \cs_if_exist:cTF {#1}
- { \__kernel_msg_error:nnx { xparse } { environment-already-defined } {#1} }
- { \__xparse_declare_env:nnnn {#1} {#2} {#3} {#4} }
- }
-\cs_new_protected:Npn \RenewDocumentEnvironment #1#2#3#4
- {
- \cs_if_exist:cTF {#1}
- { \__xparse_declare_env:nnnn {#1} {#2} {#3} {#4} }
- { \__kernel_msg_error:nnx { xparse } { environment-not-yet-defined } {#1} }
- }
-\cs_new_protected:Npn \ProvideDocumentEnvironment #1#2#3#4
- { \cs_if_exist:cF {#1} { \__xparse_declare_env:nnnn {#1} {#2} {#3} {#4} } }
-\cs_new_protected:Npn \DeclareDocumentEnvironment #1#2#3#4
- { \__xparse_declare_env:nnnn {#1} {#2} {#3} {#4} }
-\cs_new_protected:Npn \NewExpandableDocumentCommand #1#2#3
- {
- \__xparse_check_definable:nNT {#1} \NewExpandableDocumentCommand
- {
- \cs_if_exist:NTF #1
- {
- \__kernel_msg_error:nnxx { xparse } { command-already-defined }
- { \use:nnn \token_to_str:N #1 { } }
- { \token_to_str:N \NewExpandableDocumentCommand }
- }
- { \__xparse_declare_expandable_cmd:Nnn #1 {#2} {#3} }
- }
- }
-\cs_new_protected:Npn \RenewExpandableDocumentCommand #1#2#3
- {
- \__xparse_check_definable:nNT {#1} \RenewExpandableDocumentCommand
- {
- \cs_if_exist:NTF #1
- { \__xparse_declare_expandable_cmd:Nnn #1 {#2} {#3} }
- {
- \__kernel_msg_error:nnxx { xparse } { command-not-yet-defined }
- { \use:nnn \token_to_str:N #1 { } }
- { \token_to_str:N \RenewExpandableDocumentCommand }
- }
- }
- }
-\cs_new_protected:Npn \ProvideExpandableDocumentCommand #1#2#3
- {
- \__xparse_check_definable:nNT {#1} \ProvideExpandableDocumentCommand
- {
- \cs_if_exist:NF #1
- { \__xparse_declare_expandable_cmd:Nnn #1 {#2} {#3} }
- }
- }
-\cs_new_protected:Npn \DeclareExpandableDocumentCommand #1#2#3
- {
- \__xparse_check_definable:nNT {#1} \DeclareExpandableDocumentCommand
- { \__xparse_declare_expandable_cmd:Nnn #1 {#2} {#3} }
- }
-\cs_new:Npn \IfBooleanTF #1
- {
- \tl_if_single:nF {#1}
- { \prg_break:n { \use:n } }
- \tl_if_single_token:nF #1
- { \prg_break:n { \use:n } }
- \token_if_eq_meaning:NNT #1 \c_true_bool
- { \prg_break:n { \use_ii:nnn } }
- \token_if_eq_meaning:NNT #1 \c_false_bool
- { \prg_break:n { \use_iii:nnn } }
- \prg_break:n { \use:n }
- \prg_break_point:
- {
- \__kernel_msg_expandable_error:nnn { xparse } { if-boolean } {#1}
- \use_ii:nn
- }
- }
-\cs_new:Npn \IfBooleanT #1#2 { \IfBooleanTF {#1} {#2} { } }
-\cs_new:Npn \IfBooleanF #1 { \IfBooleanTF {#1} { } }
-\cs_new_eq:NN \IfNoValueF \tl_if_novalue:nF
-\cs_new_eq:NN \IfNoValueT \tl_if_novalue:nT
-\cs_new_eq:NN \IfNoValueTF \tl_if_novalue:nTF
-\cs_new:Npn \IfValueF { \tl_if_novalue:nT }
-\cs_new:Npn \IfValueT { \tl_if_novalue:nF }
-\cs_new:Npn \IfValueTF #1#2#3 { \tl_if_novalue:nTF {#1} {#3} {#2} }
-\tl_new:N \ProcessedArgument
-\cs_new_eq:NN \ReverseBoolean \__xparse_bool_reverse:N
-\cs_new_eq:NN \SplitArgument \__xparse_split_argument:nnn
-\cs_new_eq:NN \SplitList \__xparse_split_list:nn
-\cs_new_eq:NN \TrimSpaces \__xparse_trim_spaces:n
-\cs_new_eq:NN \ProcessList \tl_map_function:nN
-\cs_new_protected:Npn \GetDocumentCommandArgSpec #1
- {
- \__xparse_check_definable:nNT {#1} \GetDocumentCommandArgSpec
- { \__xparse_get_arg_spec:N #1 }
- }
-\cs_new_eq:NN \GetDocumentEnvironmentArgSpec \__xparse_get_arg_spec:n
-\cs_new_protected:Npn \ShowDocumentCommandArgSpec #1
- {
- \__xparse_check_definable:nNT {#1} \ShowDocumentCommandArgSpec
- { \__xparse_show_arg_spec:N #1 }
- }
-\cs_new_eq:NN \ShowDocumentEnvironmentArgSpec \__xparse_show_arg_spec:n
%%
%%
%% End of file `xparse.sty'.
diff --git a/Master/texmf-dist/tex/latex/l3packages/xtemplate/xtemplate.sty b/Master/texmf-dist/tex/latex/l3packages/xtemplate/xtemplate.sty
index ec99bc7a32c..d0cc5e4f09a 100644
--- a/Master/texmf-dist/tex/latex/l3packages/xtemplate/xtemplate.sty
+++ b/Master/texmf-dist/tex/latex/l3packages/xtemplate/xtemplate.sty
@@ -32,7 +32,7 @@
}%
\endinput
}
-\ProvidesExplPackage{xtemplate}{2020-03-06}{}
+\ProvidesExplPackage{xtemplate}{2020-05-14}{}
{L3 Experimental prototype document functions}
\tl_const:Nn \c__xtemplate_code_root_tl { template~code~>~ }
\tl_const:Nn \c__xtemplate_defaults_root_tl { template~defaults~>~ }
@@ -68,6 +68,10 @@
\muskip_new:N \l__xtemplate_tmp_muskip
\skip_new:N \l__xtemplate_tmp_skip
\tl_new:N \l__xtemplate_tmp_tl
+\scan_new:N \s__xtemplate_mark
+\scan_new:N \s__xtemplate_stop
+\quark_new:N \q__xtemplate_nil
+\__kernel_quark_new_conditional:Nn \__xtemplate_quark_if_nil:N { F }
\cs_generate_variant:Nn \prop_get:NnNTF { No }
\cs_generate_variant:Nn \prop_get:NnNT { No }
\cs_generate_variant:Nn \prop_get:NnNF { No }
@@ -330,7 +334,7 @@
{
\tl_clear:N \l__xtemplate_key_name_tl
\exp_after:wN \__xtemplate_split_keytype_aux:w
- \l__xtemplate_tmp_tl \q_stop
+ \l__xtemplate_tmp_tl \s__xtemplate_stop
}
}
{
@@ -341,7 +345,7 @@
\use:x
{
\cs_new_protected:Npn \exp_not:N \__xtemplate_split_keytype_aux:w
- ##1 \token_to_str:N : ##2 \exp_not:N \q_stop
+ ##1 \token_to_str:N : ##2 \s__xtemplate_stop
{
\tl_put_right:Nx \exp_not:N \l__xtemplate_key_name_tl
{ \exp_not:N \tl_to_str:n {##1} }
@@ -349,7 +353,7 @@
{
\tl_put_right:Nn \exp_not:N \l__xtemplate_key_name_tl
{ \token_to_str:N : }
- \exp_not:N \__xtemplate_split_keytype_aux:w ##2 \exp_not:N \q_stop
+ \exp_not:N \__xtemplate_split_keytype_aux:w ##2 \s__xtemplate_stop
}
{
\exp_not:N \tl_if_empty:NTF \exp_not:N \l__xtemplate_key_name_tl
@@ -370,7 +374,7 @@
\tl_if_in:nnT {#1} {##1}
{
\cs_set:Npn \__xtemplate_split_keytype_arg_aux:w
- ####1 ##1 ####2 \q_stop
+ ####1 ##1 ####2 \s__xtemplate_stop
{
\tl_if_empty:nT {####1}
{
@@ -379,7 +383,7 @@
\seq_map_break:
}
}
- \__xtemplate_split_keytype_arg_aux:w #1 \q_stop
+ \__xtemplate_split_keytype_arg_aux:w #1 \s__xtemplate_stop
}
}
\seq_map_function:NN \c__xtemplate_keytypes_arg_seq
@@ -387,7 +391,7 @@
}
\cs_generate_variant:Nn \__xtemplate_split_keytype_arg:n { o }
\cs_new:Npn \__xtemplate_split_keytype_arg_aux:n #1 { }
-\cs_new:Npn \__xtemplate_split_keytype_arg_aux:w #1 \q_stop { }
+\cs_new:Npn \__xtemplate_split_keytype_arg_aux:w #1 \s__xtemplate_stop { }
\cs_new_protected:Npn \__xtemplate_store_value_boolean:n #1
{
\__xtemplate_if_eval_now:nTF {#1}
@@ -531,7 +535,7 @@
}
{
\tl_if_in:nnTF {#1} { global }
- { \__xtemplate_parse_vars_elt_aux:w #1 \q_stop }
+ { \__xtemplate_parse_vars_elt_aux:w #1 \s__xtemplate_stop }
{
\msg_error:nnx { xtemplate } { bad-variable }
{ \tl_to_str:n {#1} }
@@ -540,7 +544,7 @@
}
}
}
-\cs_new_protected:Npn \__xtemplate_parse_vars_elt_aux:w #1 global #2 \q_stop
+\cs_new_protected:Npn \__xtemplate_parse_vars_elt_aux:w #1 global #2 \s__xtemplate_stop
{
\tl_if_empty:nTF {#1}
{
@@ -812,10 +816,10 @@
\bool_set_false:N \l__xtemplate_global_bool
\tl_if_in:onT \l__xtemplate_var_tl { global }
{
- \exp_after:wN \__xtemplate_find_global_aux:w \l__xtemplate_var_tl \q_stop
+ \exp_after:wN \__xtemplate_find_global_aux:w \l__xtemplate_var_tl \s__xtemplate_stop
}
}
-\cs_new_protected:Npn \__xtemplate_find_global_aux:w #1 global #2 \q_stop
+\cs_new_protected:Npn \__xtemplate_find_global_aux:w #1 global #2 \s__xtemplate_stop
{
\tl_set:Nn \l__xtemplate_var_tl {#2}
\bool_set_true:N \l__xtemplate_global_bool
@@ -1011,16 +1015,16 @@
\l__xtemplate_value_tl
{
\exp_after:wN \__xtemplate_key_to_value_auxii:w \l__xtemplate_value_tl
- \q_mark global \q_nil \q_stop
+ \s__xtemplate_mark global \q__xtemplate_nil \s__xtemplate_stop
}
{
\msg_error:nnx { xtemplate } { unknown-attribute }
{ \l__xtemplate_tmp_tl }
}
}
-\cs_new_protected:Npn \__xtemplate_key_to_value_auxii:w #1 global #2#3 \q_stop
+\cs_new_protected:Npn \__xtemplate_key_to_value_auxii:w #1 global #2#3 \s__xtemplate_stop
{
- \quark_if_nil:NF #2
+ \__xtemplate_quark_if_nil:NF #2
{ \tl_set:Nn \l__xtemplate_value_tl {#2} }
}
\cs_new_protected:Npn \__xtemplate_use_instance:nn #1#2