diff options
Diffstat (limited to 'Master/texmf-dist/tex/latex/expl3/l3tl.sty')
-rw-r--r-- | Master/texmf-dist/tex/latex/expl3/l3tl.sty | 21 |
1 files changed, 12 insertions, 9 deletions
diff --git a/Master/texmf-dist/tex/latex/expl3/l3tl.sty b/Master/texmf-dist/tex/latex/expl3/l3tl.sty index e334d246130..cacec3e0fdf 100644 --- a/Master/texmf-dist/tex/latex/expl3/l3tl.sty +++ b/Master/texmf-dist/tex/latex/expl3/l3tl.sty @@ -48,7 +48,7 @@ %% %% ----------------------------------------------------------------------- \RequirePackage{l3names} -\GetIdInfo$Id: l3tl.dtx 2138 2011-01-26 08:15:27Z joseph $ +\GetIdInfo$Id: l3tl.dtx 2184 2011-03-07 18:07:12Z joseph $ {L3 Experimental Token Lists} \ProvidesExplPackage {\filename}{\filedate}{\fileversion}{\filedescription} @@ -446,14 +446,13 @@ \_tl_replace_in_aux:NNnn \tl_set_eq:NN } \cs_new_protected:Npn \_tl_replace_in_aux:NNnn #1#2#3#4 { - \cs_set:Npn \_tl_tmp:w ##1 #3 ##2 \q_stop + \cs_set_protected:Npn \_tl_tmp:w ##1 #3 ##2 \q_stop { \quark_if_no_value:nF {##2} { \tl_set:No \_l_tl_replace_tl { ##1 #4 } - \cs_set:Npn \_tl_tmp:w ####1 #3 \q_no_value { - \tl_put_right:No \_l_tl_replace_tl {####1} - } + \cs_set_protected:Npn \_tl_tmp:w ####1 \q_nil #3 \q_no_value + { \tl_put_right:No \_l_tl_replace_tl {####1} } \_tl_tmp:w \prg_do_nothing: ##2 #1 #2 \_l_tl_replace_tl } @@ -463,7 +462,7 @@ \exp_after:wN \_tl_tmp:w \exp_after:wN \prg_do_nothing: } - #2 #3 \q_no_value \q_stop + #2 \q_nil #3 \q_no_value \q_stop } \cs_new_protected_nopar:Npn \tl_greplace_in:Nnn { \_tl_replace_in_aux:NNnn \tl_gset_eq:NN @@ -478,10 +477,14 @@ } \cs_new_protected:Npn \_tl_replace_all_in_aux:NNnn #1#2#3#4 { \tl_clear:N \_l_tl_replace_tl - \cs_set:Npn \_tl_tmp:w ##1 #3 ##2 \q_stop + \cs_set_protected:Npn \_tl_tmp:w ##1 #3 ##2 \q_stop { \quark_if_no_value:nTF {##2} - { \tl_put_right:No \_l_tl_replace_tl {##1} } + { + \cs_set_protected:Npn \_tl_tmp:w ####1 \q_nil ####2 \q_stop + { \tl_put_right:No \_l_tl_replace_tl {####1} } + \_tl_tmp:w ##1 \q_stop + } { \tl_put_right:No \_l_tl_replace_tl { ##1 #4 } \_tl_tmp:w \prg_do_nothing: ##2 \q_stop @@ -492,7 +495,7 @@ \exp_after:wN \_tl_tmp:w \exp_after:wN \prg_do_nothing: } - #2 #3 \q_no_value \q_stop + #2 \q_nil #3 \q_no_value \q_stop #1 #2 \_l_tl_replace_tl } \cs_generate_variant:Nn \tl_replace_all_in:Nnn { c } |