[latex3-commits] [git/LaTeX3-latex3-latex2e] gh569: Add tests for copying ltcmd commands (e3605e48)
PhelypeOleinik
phelype.oleinik at latex-project.org
Mon Aug 9 00:58:03 CEST 2021
Repository : https://github.com/latex3/latex2e
On branch : gh569
Link : https://github.com/latex3/latex2e/commit/e3605e48e2c5c8fd3b77c4d7fd16049e1ff7dff2
>---------------------------------------------------------------
commit e3605e48e2c5c8fd3b77c4d7fd16049e1ff7dff2
Author: PhelypeOleinik <phelype.oleinik at latex-project.org>
Date: Sun Aug 8 19:58:03 2021 -0300
Add tests for copying ltcmd commands
>---------------------------------------------------------------
e3605e48e2c5c8fd3b77c4d7fd16049e1ff7dff2
base/testfiles-ltcmd/github-569.lvt | 33 ++++++++++++++++
base/testfiles-ltcmd/github-569.tlg | 78 +++++++++++++++++++++++++++++++++++++
2 files changed, 111 insertions(+)
diff --git a/base/testfiles-ltcmd/github-569.lvt b/base/testfiles-ltcmd/github-569.lvt
new file mode 100644
index 00000000..260ffaac
--- /dev/null
+++ b/base/testfiles-ltcmd/github-569.lvt
@@ -0,0 +1,33 @@
+\input{test2e}
+
+\START
+
+
+\DeclareDocumentCommand\foo{m+oD(){bar}+vm!>{\SplitList{;}}O{b;a;z}t^e{_^}}
+ {\typeout{##1:#1^^J##2:#2^^J##3:#3^^J##4:#4^^J##5:#5^^J##6:#6^^J##7:#7^^J##8:#8^^J##9:#9^^J}}
+
+\typeout{\string\foo=\meaning\foo}
+\foo{a}[b](c)|f|{g}[h;i;j]^_d^e
+\foo{a}|f|{g}
+
+\DeclareCommandCopy\bar\foo
+
+\typeout{\string\bar=\meaning\bar}
+\bar{a}[b](c)|f|{g}[h;i;j]^_d^e
+\foo{a}|f|{g}
+
+
+\DeclareExpandableDocumentCommand\foo{moD(){bar}mO{b;a;z}+t^+e{_^}+m}
+ {\typeout{##1:#1^^J##2:#2^^J##3:#3^^J##4:#4^^J##5:#5^^J##6:#6^^J##7:#7^^J##8:#8^^J##9:#9^^J}}
+
+\typeout{\string\foo=\meaning\foo}
+\foo{a}[b](c){g}[h;i;j]^_d^e{f}
+\foo{a}{g}{f}
+
+\DeclareCommandCopy\bar\foo
+
+\typeout{\string\bar=\meaning\bar}
+\bar{a}[b](c){g}[h;i;j]^_d^e{f}
+\foo{a}{g}{f}
+
+\END
diff --git a/base/testfiles-ltcmd/github-569.tlg b/base/testfiles-ltcmd/github-569.tlg
new file mode 100644
index 00000000..6848fa35
--- /dev/null
+++ b/base/testfiles-ltcmd/github-569.tlg
@@ -0,0 +1,78 @@
+This is a generated file for the LaTeX2e validation system.
+Don't change this file in any respect.
+\foo=\protected macro:->\__cmd_start:nNNnnn {m+oD(){bar}+vm!>{\SplitList {;}}O{b;a;z}t^e{_^}}\foo \foo code {\__cmd_grab_m_1:w \__cmd_grab_D_long:w []\__cmd_grab_D:w ()\__cmd_grab_v_long:w \__cmd_grab_m_1:w \__cmd_grab_D_obey_spaces:w []\__cmd_grab_t:w ^\__cmd_grab_E:w {_^}}{\c_novalue_tl \c_novalue_tl {\prg_do_nothing: bar}\c_novalue_tl \c_novalue_tl {\prg_do_nothing: b;a;z}\c_novalue_tl \c_novalue_tl \c_novalue_tl }{{}{}{}{}{}{{\SplitList {;}}}{}{}{}}
+##1:a
+##2:b
+##3:c
+##4:f
+##5:g
+##6:{h}{i}{j}
+##7:\BooleanTrue
+##8:d
+##9:e
+##1:a
+##2:-NoValue-
+##3:bar
+##4:f
+##5:g
+##6:{b}{a}{z}
+##7:\BooleanFalse
+##8:-NoValue-
+##9:-NoValue-
+\bar=\protected macro:->\__cmd_start:nNNnnn {m+oD(){bar}+vm!>{\SplitList {;}}O{b;a;z}t^e{_^}}\bar \bar code {\__cmd_grab_m_1:w \__cmd_grab_D_long:w []\__cmd_grab_D:w ()\__cmd_grab_v_long:w \__cmd_grab_m_1:w \__cmd_grab_D_obey_spaces:w []\__cmd_grab_t:w ^\__cmd_grab_E:w {_^}}{\c_novalue_tl \c_novalue_tl {\prg_do_nothing: bar}\c_novalue_tl \c_novalue_tl {\prg_do_nothing: b;a;z}\c_novalue_tl \c_novalue_tl \c_novalue_tl }{{}{}{}{}{}{{\SplitList {;}}}{}{}{}}
+##1:a
+##2:b
+##3:c
+##4:f
+##5:g
+##6:{h}{i}{j}
+##7:\BooleanTrue
+##8:d
+##9:e
+##1:a
+##2:-NoValue-
+##3:bar
+##4:f
+##5:g
+##6:{b}{a}{z}
+##7:\BooleanFalse
+##8:-NoValue-
+##9:-NoValue-
+\foo=macro:->\__cmd_start_expandable:nNNNNn {moD(){bar}mO{b;a;z}+t^+e{_^}+m}\foo \foo \foo code \foo defaults {\__cmd_expandable_grab_m:w \__cmd_expandable_grab_D:w \foo (arg 2) []\__cmd_expandable_grab_D:w \foo (arg 3) ()\__cmd_expandable_grab_m:w \__cmd_expandable_grab_D:w \foo (arg 5) []\__cmd_expandable_grab_t:w \__cmd_grabber_^:w ^\__cmd_expandable_grab_E_long:w {\__cmd_grabber__:w _\__cmd_grabber_^:w ^}{{-NoValue-}{-NoValue-}}\__cmd_expandable_grab_m_long:w }
+##1:a
+##2:b
+##3:c
+##4:g
+##5:h;i;j
+##6:\BooleanTrue
+##7:d
+##8:e
+##9:f
+##1:a
+##2:-NoValue-
+##3:bar
+##4:g
+##5:b;a;z
+##6:\BooleanFalse
+##7:-NoValue-
+##8:-NoValue-
+##9:f
+\bar=macro:->\__cmd_start_expandable:nNNNNn {moD(){bar}mO{b;a;z}+t^+e{_^}+m}\bar \bar \bar code \bar defaults {\__cmd_expandable_grab_m:w \__cmd_expandable_grab_D:w \bar (arg 2) []\__cmd_expandable_grab_D:w \bar (arg 3) ()\__cmd_expandable_grab_m:w \__cmd_expandable_grab_D:w \bar (arg 5) []\__cmd_expandable_grab_t:w \__cmd_grabber_^:w ^\__cmd_expandable_grab_E_long:w {\__cmd_grabber__:w _\__cmd_grabber_^:w ^}{{-NoValue-}{-NoValue-}}\__cmd_expandable_grab_m_long:w }
+##1:a
+##2:b
+##3:c
+##4:g
+##5:h;i;j
+##6:\BooleanTrue
+##7:d
+##8:e
+##9:f
+##1:a
+##2:-NoValue-
+##3:bar
+##4:g
+##5:b;a;z
+##6:\BooleanFalse
+##7:-NoValue-
+##8:-NoValue-
+##9:f
More information about the latex3-commits
mailing list.