diff options
Diffstat (limited to 'Master/texmf-dist/source/latex/expl3/l3clist.dtx')
-rw-r--r-- | Master/texmf-dist/source/latex/expl3/l3clist.dtx | 56 |
1 files changed, 26 insertions, 30 deletions
diff --git a/Master/texmf-dist/source/latex/expl3/l3clist.dtx b/Master/texmf-dist/source/latex/expl3/l3clist.dtx index f8fdba275bb..1bee2934399 100644 --- a/Master/texmf-dist/source/latex/expl3/l3clist.dtx +++ b/Master/texmf-dist/source/latex/expl3/l3clist.dtx @@ -32,25 +32,21 @@ %% %% ----------------------------------------------------------------------- % -%<package>\RequirePackage{l3names} -%<*dtx> +%<*driver|package> +\RequirePackage{l3names} +%</driver|package> %\fi -\def\GetIdInfo$Id: #1.dtx #2 #3-#4-#5 #6 #7$#8{% - \def\fileversion{#2}% - \def\filedate{#3/#4/#5}% - \ProvidesFile{#1.dtx}[#3/#4/#5 v#2 #8]% -} -%\iffalse -%</dtx> -%\fi -\GetIdInfo$Id: l3clist.dtx 573 2006-08-21 20:59:37Z morten $ +\GetIdInfo$Id: l3clist.dtx 725 2007-12-22 21:25:00Z mittelba $ {L3 Experimental comma separated lists} -% -% \iffalse +%\iffalse %<*driver> +%\fi +\ProvidesFile{\filename.\filenameext} + [\filedate\space v\fileversion\space\filedescription] +%\iffalse \documentclass{l3doc} \begin{document} -\DocInput{l3clist.dtx} +\DocInput{\filename.\filenameext} \end{document} %</driver> % \fi @@ -459,6 +455,8 @@ % % We start by ensuring that the required packages are loaded. % \begin{macrocode} +%<package>\ProvidesExplPackage +%<package> {\filename}{\filedate}{\fileversion}{\filedescription} %<*package> \NeedsTeXFormat{LaTeX2e} %<!check>\RequirePackage{l3prg,l3quark} @@ -693,7 +691,7 @@ % An here the global variants. % \begin{macrocode} \def_new:Npn \clist_gput_right:Nn { - \clist_put_aux:NNnnNn \tlp_set:Nn \tlp_put_right:Nn , {} + \clist_put_aux:NNnnNn \tlp_gset:Nn \tlp_gput_right:Nn , {} } \def_new:Npn \clist_gput_right:No {\exp_args:NNo \clist_gput_right:Nn} \def_new:Npn \clist_gput_right:cn {\exp_args:Nc \clist_gput_right:Nn} @@ -720,13 +718,13 @@ \clist_if_empty:NF #1 { \exp_after:NN \clist_map_function_aux:Nw - \exp_after:NN #2 #1 , \q_nil , \q_stop + \exp_after:NN #2 #1 , \q_recursion_tail , \q_recursion_stop } } \def_new:Npn \clist_map_function:cN{\exp_args:Nc\clist_map_function:NN} \def_new:Npn \clist_map_function:nN #1#2{ - \tlist_if_empty:nF {#1} - { \clist_map_function_aux:Nw #2 #1 , \q_nil , \q_stop } + \tlist_if_blank:nF {#1} + { \clist_map_function_aux:Nw #2 #1 , \q_recursion_tail , \q_recursion_stop } } % \end{macrocode} % \end{macro} @@ -739,7 +737,7 @@ % element "#2", which is surrounded by braces. % \begin{macrocode} \def_new:Npn \clist_map_function_aux:Nw #1#2,{ - \quark_if_nil:nT{#2} \clist_map_break:w + \quark_if_recursion_tail_stop:n{#2} #1{#2} \clist_map_function_aux:Nw #1 } @@ -747,13 +745,10 @@ % \end{macro} % % \begin{macro}{\clist_map_break:w} -% The break statement is easy: Just gobble everything op to the last -% of the two stop markers "\q_stop" waiting at the end and close the -% "\if_..." we're in. Technically this should get an "w" specifier, -% but it doesn't take any arguments when you call it -- at least not -% any you would expect. +% The break statement is easy. Same as in other modules, gobble +% everything up to the special recursion stop marker. % \begin{macrocode} -\let_new:NN \clist_map_break:w \use_none_delimit_by_q_stop:w +\let_new:NN \clist_map_break:w \use_none_delimit_by_q_recursion_stop:w % \end{macrocode} % \end{macro} % @@ -782,7 +777,7 @@ % \begin{macrocode} \exp_args:NcE \clist_map_function_aux:Nw {clist_map_inline_ \int_use:N \l_clist_inline_level_int :n} - #1 , \q_nil , \q_stop + #1 , \q_recursion_tail , \q_recursion_stop \int_decr:N \l_clist_inline_level_int } } @@ -795,7 +790,7 @@ ##1{#2} \exp_args:Nc \clist_map_function_aux:Nw {clist_map_inline_ \int_use:N \l_clist_inline_level_int :n} - #1 , \q_nil , \q_stop + #1 , \q_recursion_tail , \q_recursion_stop \int_decr:N \l_clist_inline_level_int } } @@ -814,7 +809,8 @@ \def_new:Npn \clist_map_variable:nNn #1#2#3{ \tlist_if_empty:nF{#1} { - \clist_map_variable_aux:Nnw #2 {#3} #1 , \q_nil , \q_stop + \clist_map_variable_aux:Nnw #2 {#3} #1 + , \q_recursion_tail , \q_recursion_stop } } \def_new:Npn \clist_map_variable:NNn {\exp_args:No \clist_map_variable:nNn} @@ -831,7 +827,7 @@ % \begin{macrocode} \def_new:Npn \clist_map_variable_aux:Nnw #1#2#3,{ \def:Npn #1{#3} - \quark_if_nil:NT #1 \clist_map_break:w + \quark_if_recursion_tail_stop:N #1 #2 \clist_map_variable_aux:Nnw #1{#2} } % \end{macrocode} @@ -923,7 +919,7 @@ \if_meaning:NN #1 \scan_stop: % \end{macrocode} % \dots\ if \m{clist} equals |\scan_stop:| it is probably stemming -% from a |\cs:w ... \cd_end:| that was created by mistake somewhere. +% from a |\cs:w ... \cs_end:| that was created by mistake somewhere. % \begin{macrocode} \err_latex_bug:x {Comma~list~ `\token_to_string:N #1'~ has~ an~ erroneous~ structure!} |