diff options
Diffstat (limited to 'Master/texmf-dist/tex/latex')
28 files changed, 613 insertions, 280 deletions
diff --git a/Master/texmf-dist/tex/latex/l3experimental/l3sort/l3sort.sty b/Master/texmf-dist/tex/latex/l3experimental/l3sort/l3sort.sty index 71ce3d901e9..e1129ef82da 100644 --- a/Master/texmf-dist/tex/latex/l3experimental/l3sort/l3sort.sty +++ b/Master/texmf-dist/tex/latex/l3experimental/l3sort/l3sort.sty @@ -47,7 +47,7 @@ %% ----------------------------------------------------------------------- %% \RequirePackage{expl3} -\GetIdInfo$Id: l3sort.dtx 4491 2013-05-12 16:22:18Z bruno $ +\GetIdInfo$Id: l3sort.dtx 4566 2013-07-24 19:34:45Z bruno $ {L3 Experimental sorting functions} \ProvidesExplPackage {\ExplFileName}{\ExplFileDate}{\ExplFileVersion}{\ExplFileDescription} @@ -85,13 +85,13 @@ { \__sort_main:NNNnNn \tl_set:Nn \seq_map_inline:Nn \seq_map_break: - { \__sort_toks:NNw \exp_not:N \__seq_item:n 0 ; } + { \s__seq \__sort_toks:NNw \exp_not:N \__seq_item:n 0 ; \s_obj_end } } \cs_new_protected_nopar:Npn \seq_gsort:Nn { \__sort_main:NNNnNn \tl_gset:Nn \seq_map_inline:Nn \seq_map_break: - { \__sort_toks:NNw \exp_not:N \__seq_item:n 0 ; } + { \s__seq \__sort_toks:NNw \exp_not:N \__seq_item:n 0 ; \s_obj_end } } \cs_new_protected_nopar:Npn \tl_sort:Nn { diff --git a/Master/texmf-dist/tex/latex/l3experimental/l3str/l3regex-trace.sty b/Master/texmf-dist/tex/latex/l3experimental/l3str/l3regex-trace.sty index a06c2d882db..16337136351 100644 --- a/Master/texmf-dist/tex/latex/l3experimental/l3str/l3regex-trace.sty +++ b/Master/texmf-dist/tex/latex/l3experimental/l3str/l3regex-trace.sty @@ -46,7 +46,7 @@ %% %% ----------------------------------------------------------------------- \RequirePackage{expl3} -\GetIdInfo$Id: l3regex.dtx 4482 2013-04-24 21:05:12Z joseph $ +\GetIdInfo$Id: l3regex.dtx 4576 2013-07-24 21:40:24Z joseph $ {L3 Experimental regular expressions} \ProvidesExplPackage {\ExplFileName}{\ExplFileDate}{\ExplFileVersion}{\ExplFileDescription} @@ -973,13 +973,12 @@ { \token_if_eq_meaning:NNT \__regex_compile_special:N #1 { - \str_case:nnn { #2 } + \str_case:nn { #2 } { : { \__regex_compile_class_posix:NNNNw } = { \__msg_kernel_warning:nnx { regex } { posix-unsupported } { = } } . { \__msg_kernel_warning:nnx { regex } { posix-unsupported } { . } } } - { } } \__regex_compile_raw:N [ #1 #2 } @@ -1387,7 +1386,7 @@ \__regex_show_push:n {~} #2 \exp_last_unbraced:Nf - \int_case:nnn { \l__regex_show_lines_int } + \int_case:nnF { \l__regex_show_lines_int } { {0} { @@ -1422,7 +1421,7 @@ \cs_new:Npn \__regex_show_anchor_to_str:N #1 { anchor~at~ - \str_case:nnn { #1 } + \str_case:nnF { #1 } { { \l__regex_min_pos_int } { start~(\iow_char:N\\A) } { \l__regex_start_pos_int } { start~of~match~(\iow_char:N\\G) } @@ -2434,11 +2433,13 @@ \flag_clear:n { __regex_end } \tl_set:Nx \l__regex_internal_a_tl { + \s__seq \int_step_function:nnnN { \c_two * \l__regex_max_state_int } \c_one { \l__regex_submatch_int - \c_one } \__regex_extract_seq_aux:n + \s_obj_end } \int_compare:nNnF { \flag_height:n { __regex_begin } + \flag_height:n { __regex_end } } @@ -2804,7 +2805,7 @@ \str_if_eq_x:nnF { #1 #2 } { 1 0 } { , ~ repeated ~ - \int_case:nnn {#2} + \int_case:nnF {#2} { { -1 } { #1~or~more~times,~\bool_if:NTF #3 { lazy } { greedy } } { 0 } { #1~times } diff --git a/Master/texmf-dist/tex/latex/l3experimental/l3str/l3regex.sty b/Master/texmf-dist/tex/latex/l3experimental/l3str/l3regex.sty index f3438ed74f6..a04fee919c5 100644 --- a/Master/texmf-dist/tex/latex/l3experimental/l3str/l3regex.sty +++ b/Master/texmf-dist/tex/latex/l3experimental/l3str/l3regex.sty @@ -46,7 +46,7 @@ %% %% ----------------------------------------------------------------------- \RequirePackage{expl3} -\GetIdInfo$Id: l3regex.dtx 4482 2013-04-24 21:05:12Z joseph $ +\GetIdInfo$Id: l3regex.dtx 4576 2013-07-24 21:40:24Z joseph $ {L3 Experimental regular expressions} \ProvidesExplPackage {\ExplFileName}{\ExplFileDate}{\ExplFileVersion}{\ExplFileDescription} @@ -971,13 +971,12 @@ { \token_if_eq_meaning:NNT \__regex_compile_special:N #1 { - \str_case:nnn { #2 } + \str_case:nn { #2 } { : { \__regex_compile_class_posix:NNNNw } = { \__msg_kernel_warning:nnx { regex } { posix-unsupported } { = } } . { \__msg_kernel_warning:nnx { regex } { posix-unsupported } { . } } } - { } } \__regex_compile_raw:N [ #1 #2 } @@ -1385,7 +1384,7 @@ \__regex_show_push:n {~} #2 \exp_last_unbraced:Nf - \int_case:nnn { \l__regex_show_lines_int } + \int_case:nnF { \l__regex_show_lines_int } { {0} { @@ -1420,7 +1419,7 @@ \cs_new:Npn \__regex_show_anchor_to_str:N #1 { anchor~at~ - \str_case:nnn { #1 } + \str_case:nnF { #1 } { { \l__regex_min_pos_int } { start~(\iow_char:N\\A) } { \l__regex_start_pos_int } { start~of~match~(\iow_char:N\\G) } @@ -2407,11 +2406,13 @@ \flag_clear:n { __regex_end } \tl_set:Nx \l__regex_internal_a_tl { + \s__seq \int_step_function:nnnN { \c_two * \l__regex_max_state_int } \c_one { \l__regex_submatch_int - \c_one } \__regex_extract_seq_aux:n + \s_obj_end } \int_compare:nNnF { \flag_height:n { __regex_begin } + \flag_height:n { __regex_end } } @@ -2777,7 +2778,7 @@ \str_if_eq_x:nnF { #1 #2 } { 1 0 } { , ~ repeated ~ - \int_case:nnn {#2} + \int_case:nnF {#2} { { -1 } { #1~or~more~times,~\bool_if:NTF #3 { lazy } { greedy } } { 0 } { #1~times } diff --git a/Master/texmf-dist/tex/latex/l3experimental/l3str/l3str-format.sty b/Master/texmf-dist/tex/latex/l3experimental/l3str/l3str-format.sty index bbf68b78646..0cdd5c2bbcf 100644 --- a/Master/texmf-dist/tex/latex/l3experimental/l3str/l3str-format.sty +++ b/Master/texmf-dist/tex/latex/l3experimental/l3str/l3str-format.sty @@ -237,16 +237,20 @@ \cs_new:Npn \seq_format:Nn #1#2 { \tl_to_str:f - { \__str_format_seq:of {#1} { \__str_format_parse:n {#2} } } + { + \__str_format_seq:ff { \exp_after:wN \__str_format_seq_extract:w #1 } + { \__str_format_parse:n {#2} } + } } \cs_generate_variant:Nn \seq_format:Nn { c } +\cs_new:Npn \__str_format_seq_extract:w \s__seq #1 \s_obj_end { \exp_stop_f: #1 } \cs_new:Npn \__str_format_seq:nn #1#2 { \__str_format_seq_loop:nnNn { } {#2} #1 { ? \__str_format_seq_end:w } { } } -\cs_generate_variant:Nn \__str_format_seq:nn { of } +\cs_generate_variant:Nn \__str_format_seq:nn { ff } \cs_new:Npn \__str_format_seq_loop:nnNn #1#2#3#4 { \use_none:n #3 @@ -274,7 +278,7 @@ \int_compare:nNnTF {#7} < \c_zero { \__str_format_put:nw { - } } { - \str_case:nnn {#3} + \str_case:nnF {#3} { { ~ } { \__str_format_put:ow { \c_catcode_other_space_tl } } { + } { \__str_format_put:nw { + } } @@ -287,7 +291,7 @@ \__msg_kernel_expandable_error:nnnn { str } { invalid-precision-format } {#5} {int} } - \str_case:nnn {#6} + \str_case:nnF {#6} { { ? } { \__str_format_int:NwnnNNn \use:n } { d } { \__str_format_int:NwnnNNn \use:n } @@ -330,7 +334,7 @@ \token_if_eq_meaning:NNTF 2 #8 { \__str_format_put:nw { - } } { - \str_case:nnn {#3} + \str_case:nnF {#3} { { ~ } { \__str_format_put:ow { \c_catcode_other_space_tl } } { + } { \__str_format_put:nw { + } } @@ -341,7 +345,7 @@ \tl_if_empty:nTF {#5} { \__str_format_put:nw { { 6} } } { \__str_format_put:nw { {#5} } } - \str_case:nnn {#6} + \str_case:nnF {#6} { { e } { \__str_format_fp:wnnnNNw \__str_format_fp_e:wn } { f } { \__str_format_fp:wnnnNNw \__str_format_fp_f:wn } @@ -374,7 +378,7 @@ \group_end: \cs_new:Npn \__str_format_fp_e:wn \s__fp \__fp_chk:w #1#2#3 ; #4 { - \int_case:nnn {#1} + \int_case:nnF {#1} { {0} { \use:nf { 0 . } { \prg_replicate:nn {#4} { 0 } } e 0 } {2} { inf } @@ -406,7 +410,7 @@ } \cs_new:Npn \__str_format_fp_f:wn \s__fp \__fp_chk:w #1#2#3 ; #4 { - \int_case:nnn {#1} + \int_case:nnF {#1} { {0} { \use:nf { 0 . } { \prg_replicate:nn {#4} { 0 } } } {2} { inf } @@ -428,7 +432,7 @@ } \cs_new:Npn \__str_format_fp_g:wn \s__fp \__fp_chk:w #1#2 ; #3 { - \int_case:nnn {#1} + \int_case:nnF {#1} { {0} { 0 } {2} { inf } diff --git a/Master/texmf-dist/tex/latex/l3experimental/l3str/l3str.sty b/Master/texmf-dist/tex/latex/l3experimental/l3str/l3str.sty index 40b503280e3..e374955c56b 100644 --- a/Master/texmf-dist/tex/latex/l3experimental/l3str/l3str.sty +++ b/Master/texmf-dist/tex/latex/l3experimental/l3str/l3str.sty @@ -46,7 +46,7 @@ %% %% ----------------------------------------------------------------------- \RequirePackage{expl3} -\GetIdInfo$Id: l3str.dtx 4482 2013-04-24 21:05:12Z joseph $ +\GetIdInfo$Id: l3str.dtx 4576 2013-07-24 21:40:24Z joseph $ {L3 Experimental strings} \ProvidesExplPackage {\ExplFileName}{\ExplFileDate}{\ExplFileVersion}{\ExplFileDescription} diff --git a/Master/texmf-dist/tex/latex/l3kernel/expl3.sty b/Master/texmf-dist/tex/latex/l3kernel/expl3.sty index d8105f61edb..8a36ae304ff 100644 --- a/Master/texmf-dist/tex/latex/l3kernel/expl3.sty +++ b/Master/texmf-dist/tex/latex/l3kernel/expl3.sty @@ -60,8 +60,8 @@ } \def\ExplFileName{expl3} \def\ExplFileDescription{L3 Experimental code bundle wrapper} -\def\ExplFileDate{2013/07/12} -\def\ExplFileVersion{4544} +\def\ExplFileDate{2013/07/28} +\def\ExplFileVersion{4582} \RequirePackage{etex} \relax \reserveinserts{32} diff --git a/Master/texmf-dist/tex/latex/l3kernel/l3basics.sty b/Master/texmf-dist/tex/latex/l3kernel/l3basics.sty index 703d134e38b..27ccd762525 100644 --- a/Master/texmf-dist/tex/latex/l3kernel/l3basics.sty +++ b/Master/texmf-dist/tex/latex/l3kernel/l3basics.sty @@ -46,7 +46,7 @@ %% %% ----------------------------------------------------------------------- \RequirePackage{l3bootstrap} -\GetIdInfo$Id: l3basics.dtx 4521 2013-07-09 11:45:31Z joseph $ +\GetIdInfo$Id: l3basics.dtx 4581 2013-07-28 08:38:50Z joseph $ {L3 Basic definitions} \ProvidesExplPackage {\ExplFileName}{\ExplFileDate}{\ExplFileVersion}{\ExplFileDescription} @@ -809,29 +809,64 @@ \prg_return_false: \fi: } -\cs_new:Npn \str_case:nnn #1#2#3 +\cs_new:Npn \str_case:nn #1#2 { \tex_romannumeral:D - \__str_case:nw {#1} #2 {#1} {#3} \q_recursion_stop + \__str_case:nnTF {#1} {#2} { } { } } +\cs_new:Npn \str_case:nnT #1#2#3 + { + \tex_romannumeral:D + \__str_case:nnTF {#1} {#2} {#3} { } + } +\cs_new:Npn \str_case:nnF #1#2 + { + \tex_romannumeral:D + \__str_case:nnTF {#1} {#2} { } + } +\cs_new:Npn \str_case:nnTF #1#2 + { + \tex_romannumeral:D + \__str_case:nnTF {#1} {#2} + } +\cs_new:Npn \__str_case:nnTF #1#2#3#4 + { \__str_case:nw {#1} #2 {#1} { } \q_mark {#3} \q_mark {#4} \q_stop } \cs_new:Npn \__str_case:nw #1#2#3 { \str_if_eq:nnTF {#1} {#2} { \__str_case_end:nw {#3} } { \__str_case:nw {#1} } } -\cs_new:Npn \str_case_x:nnn #1#2#3 +\cs_new:Npn \str_case_x:nn #1#2 + { + \tex_romannumeral:D + \__str_case_x:nnTF {#1} {#2} { } { } + } +\cs_new:Npn \str_case_x:nnT #1#2#3 + { + \tex_romannumeral:D + \__str_case_x:nnTF {#1} {#2} {#3} { } + } +\cs_new:Npn \str_case_x:nnF #1#2 + { + \tex_romannumeral:D + \__str_case_x:nnTF {#1} {#2} { } + } +\cs_new:Npn \str_case_x:nnTF #1#2 { \tex_romannumeral:D - \__str_case_x:nw {#1} #2 {#1} {#3} \q_recursion_stop + \__str_case_x:nnTF {#1} {#2} } +\cs_new:Npn \__str_case_x:nnTF #1#2#3#4 + { \__str_case_x:nw {#1} #2 {#1} { } \q_mark {#3} \q_mark {#4} \q_stop } \cs_new:Npn \__str_case_x:nw #1#2#3 { \str_if_eq_x:nnTF {#1} {#2} { \__str_case_end:nw {#3} } { \__str_case_x:nw {#1} } } -\cs_new:Npn \__prg_case_end:nw #1#2 \q_recursion_stop { \c_zero #1 } +\cs_new:Npn \__prg_case_end:nw #1#2#3 \q_mark #4#5 \q_stop + { \c_zero #1 #4 } \cs_new_eq:NN \__str_case_end:nw \__prg_case_end:nw \cs_new_eq:NN \__prg_break_point:Nn \use_ii:nn \cs_new:Npn \__prg_map_break:Nn #1#2#3 \__prg_break_point:Nn #4#5 @@ -845,6 +880,8 @@ \cs_new_eq:NN \__prg_break_point: \prg_do_nothing: \cs_new:Npn \__prg_break: #1 \__prg_break_point: { } \cs_new:Npn \__prg_break:n #1#2 \__prg_break_point: {#1} +\cs_new_eq:NN \str_case:nnn \str_case:nnF +\cs_new_eq:NN \str_case_x:nnn \str_case_x:nnF %% %% %% End of file `l3basics.sty'. diff --git a/Master/texmf-dist/tex/latex/l3kernel/l3bootstrap.sty b/Master/texmf-dist/tex/latex/l3kernel/l3bootstrap.sty index 89dd24ceae5..9cd140d7174 100644 --- a/Master/texmf-dist/tex/latex/l3kernel/l3bootstrap.sty +++ b/Master/texmf-dist/tex/latex/l3kernel/l3bootstrap.sty @@ -102,7 +102,7 @@ {% \def\ExplFileDate{#1/#2/#3}% } -\GetIdInfo$Id: l3bootstrap.dtx 4420 2013-01-08 20:00:04Z joseph $ +\GetIdInfo$Id: l3bootstrap.dtx 4581 2013-07-28 08:38:50Z joseph $ {L3 Bootstrap code} \ProvidesPackage{l3bootstrap} [% diff --git a/Master/texmf-dist/tex/latex/l3kernel/l3box.sty b/Master/texmf-dist/tex/latex/l3kernel/l3box.sty index 32f90af3a29..1f9be4b1206 100644 --- a/Master/texmf-dist/tex/latex/l3kernel/l3box.sty +++ b/Master/texmf-dist/tex/latex/l3kernel/l3box.sty @@ -13,7 +13,7 @@ %% %% Do not distribute a modified version of this file. %% -%% File: l3box.dtx Copyright (C) 2005-2012 The LaTeX3 Project +%% File: l3box.dtx Copyright (C) 2005-2013 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 @@ -46,7 +46,7 @@ %% %% ----------------------------------------------------------------------- \RequirePackage{l3bootstrap} -\GetIdInfo$Id: l3box.dtx 4482 2013-04-24 21:05:12Z joseph $ +\GetIdInfo$Id: l3box.dtx 4581 2013-07-28 08:38:50Z joseph $ {L3 Experimental boxes} \ProvidesExplPackage {\ExplFileName}{\ExplFileDate}{\ExplFileVersion}{\ExplFileDescription} diff --git a/Master/texmf-dist/tex/latex/l3kernel/l3candidates.sty b/Master/texmf-dist/tex/latex/l3kernel/l3candidates.sty index 586823f2c55..4288b0d5288 100644 --- a/Master/texmf-dist/tex/latex/l3kernel/l3candidates.sty +++ b/Master/texmf-dist/tex/latex/l3kernel/l3candidates.sty @@ -47,7 +47,7 @@ %% ----------------------------------------------------------------------- %% \RequirePackage{l3bootstrap} -\GetIdInfo$Id: l3candidates.dtx 4521 2013-07-09 11:45:31Z joseph $ +\GetIdInfo$Id: l3candidates.dtx 4576 2013-07-24 21:40:24Z joseph $ {L3 Experimental additions to l3kernel} \ProvidesExplPackage {\ExplFileName}{\ExplFileDate}{\ExplFileVersion}{\ExplFileDescription} @@ -758,46 +758,46 @@ \cs_generate_variant:Nn \fp_gset_from_dim:Nn { c } \cs_new:Npn \prop_map_tokens:Nn #1#2 { - \exp_last_unbraced:Nno \__prop_map_tokens:nwn {#2} #1 - \s__prop \q_recursion_tail \s__prop { } + \exp_last_unbraced:Nno \__prop_map_tokens:nwwn {#2} #1 + \__prop_pair:wn \q_recursion_tail \s__prop { } \__prg_break_point:Nn \prop_map_break: { } } -\cs_new:Npn \__prop_map_tokens:nwn #1 \s__prop #2 \s__prop #3 +\cs_new:Npn \__prop_map_tokens:nwwn #1#2 \__prop_pair:wn #3 \s__prop #4 { - \if_meaning:w \q_recursion_tail #2 + \if_meaning:w \q_recursion_tail #3 \exp_after:wN \prop_map_break: \fi: - \use:n {#1} {#2} {#3} - \__prop_map_tokens:nwn {#1} + \use:n {#1} {#3} {#4} + \__prop_map_tokens:nwwn {#1} } \cs_generate_variant:Nn \prop_map_tokens:Nn { c } \cs_new:Npn \prop_get:Nn #1#2 { - \exp_last_unbraced:Noo \__prop_get_Nn:nwn { \tl_to_str:n {#2} } #1 - \s__prop \tl_to_str:n {#2} \s__prop { } + \exp_last_unbraced:Noo \__prop_get_Nn:nwwn { \tl_to_str:n {#2} } #1 + \__prop_pair:wn \tl_to_str:n {#2} \s__prop { } \__prg_break_point: } -\cs_new:Npn \__prop_get_Nn:nwn #1 \s__prop #2 \s__prop #3 +\cs_new:Npn \__prop_get_Nn:nwwn #1#2 \__prop_pair:wn #3 \s__prop #4 { - \str_if_eq_x:nnTF {#1} {#2} - { \__prg_break:n { \exp_not:n {#3} } } - { \__prop_get_Nn:nwn {#1} } + \str_if_eq_x:nnTF {#1} {#3} + { \__prg_break:n { \exp_not:n {#4} } } + { \__prop_get_Nn:nwwn {#1} } } \cs_generate_variant:Nn \prop_get:Nn { c } -\cs_new:Npn \seq_item:Nn #1#2 +\cs_new:Npn \seq_item:Nn #1 { \exp_after:wN \__seq_item:wNn #1 #1 } +\cs_new:Npn \__seq_item:wNn \s__seq #1 \s_obj_end #2#3 { - \exp_last_unbraced:Nfo \__seq_item:nnn + \exp_args:Nf \__seq_item:nnn { \int_eval:n { - \int_compare:nNnT {#2} < \c_zero - { \seq_count:N #1 + \c_one + } - #2 + \int_compare:nNnT {#3} < \c_zero + { \seq_count:N #2 + \c_one + } + #3 } } #1 - { ? \__prg_break: } - { } + { ? \__prg_break: } { } \__prg_break_point: } \cs_new:Npn \__seq_item:nnn #1#2#3 @@ -809,21 +809,18 @@ } \cs_generate_variant:Nn \seq_item:Nn { c } \cs_new:Npn \seq_mapthread_function:NNN #1#2#3 + { \exp_after:wN \__seq_mapthread_function:wNN #2 #1 #3 } +\cs_new:Npn \__seq_mapthread_function:wNN \s__seq #1 \s_obj_end #2#3 { - \exp_after:wN \__seq_mapthread_function:NN - \exp_after:wN #3 - \exp_after:wN #1 - #2 - { ? \__prg_break: } { } + \exp_after:wN \__seq_mapthread_function:wNw #2 #3 + #1 { ? \__prg_break: } { } \__prg_break_point: } -\cs_new:Npn \__seq_mapthread_function:NN #1#2 +\cs_new:Npn \__seq_mapthread_function:wNw \s__seq #1 \s_obj_end #2 { - \exp_after:wN \__seq_mapthread_function:Nnnwnn - \exp_after:wN #1 - #2 - { ? \__prg_break: } { } - \q_stop + \__seq_mapthread_function:Nnnwnn #2 + #1 { ? \__prg_break: } { } + \q_stop } \cs_new:Npn \__seq_mapthread_function:Nnnwnn #1#2#3#4 \q_stop #5#6 { @@ -837,22 +834,22 @@ \cs_new_protected:Npn \seq_set_from_clist:NN #1#2 { \tl_set:Nx #1 - { \clist_map_function:NN #2 \__seq_wrap_item:n } + { \s__seq \clist_map_function:NN #2 \__seq_wrap_item:n \s_obj_end } } \cs_new_protected:Npn \seq_set_from_clist:Nn #1#2 { \tl_set:Nx #1 - { \clist_map_function:nN {#2} \__seq_wrap_item:n } + { \s__seq \clist_map_function:nN {#2} \__seq_wrap_item:n \s_obj_end } } \cs_new_protected:Npn \seq_gset_from_clist:NN #1#2 { \tl_gset:Nx #1 - { \clist_map_function:NN #2 \__seq_wrap_item:n } + { \s__seq \clist_map_function:NN #2 \__seq_wrap_item:n \s_obj_end } } \cs_new_protected:Npn \seq_gset_from_clist:Nn #1#2 { \tl_gset:Nx #1 - { \clist_map_function:nN {#2} \__seq_wrap_item:n } + { \s__seq \clist_map_function:nN {#2} \__seq_wrap_item:n \s_obj_end } } \cs_generate_variant:Nn \seq_set_from_clist:NN { Nc } \cs_generate_variant:Nn \seq_set_from_clist:NN { c , cc } @@ -869,9 +866,11 @@ { \cs_set_eq:NN \__seq_tmp:w \__seq_item:n \cs_set_eq:NN \__seq_item:n \__seq_reverse_item:nwn - #1 #2 { #2 \exp_not:n { } } + #1 #2 { \exp_after:wN \__seq_reverse_setup:w #2 } \cs_set_eq:NN \__seq_item:n \__seq_tmp:w } +\cs_new:Npn \__seq_reverse_setup:w #1 \s_obj_end + { #1 \exp_not:n { } \s_obj_end } \cs_new:Npn \__seq_reverse_item:nwn #1 #2 \exp_not:n #3 { #2 @@ -1007,7 +1006,7 @@ { \exp_args:Nf \__tl_act_output:n { - \exp_args:NNo \str_case:nnn #2 {#1} + \exp_args:NNo \str_case:nnF #2 {#1} { \exp_stop_f: #2 } } } diff --git a/Master/texmf-dist/tex/latex/l3kernel/l3clist.sty b/Master/texmf-dist/tex/latex/l3kernel/l3clist.sty index 2a216e4ff73..5c066bd8b3e 100644 --- a/Master/texmf-dist/tex/latex/l3kernel/l3clist.sty +++ b/Master/texmf-dist/tex/latex/l3kernel/l3clist.sty @@ -48,7 +48,7 @@ %% %% ----------------------------------------------------------------------- \RequirePackage{l3bootstrap} -\GetIdInfo$Id: l3clist.dtx 4500 2013-05-26 11:18:19Z bruno $ +\GetIdInfo$Id: l3clist.dtx 4581 2013-07-28 08:38:50Z joseph $ {L3 Comma separated lists} \ProvidesExplPackage {\ExplFileName}{\ExplFileDate}{\ExplFileVersion}{\ExplFileDescription} @@ -415,7 +415,7 @@ { \clist_if_exist:NTF #1 { - \int_case:nnn { \clist_count:N #1 } + \int_case:nnF { \clist_count:N #1 } { { 0 } { } { 1 } { \exp_after:wN \__clist_use:wwn #1 , , { } } diff --git a/Master/texmf-dist/tex/latex/l3kernel/l3doc.cls b/Master/texmf-dist/tex/latex/l3kernel/l3doc.cls index d3dd89238cb..9fa07d959ef 100644 --- a/Master/texmf-dist/tex/latex/l3kernel/l3doc.cls +++ b/Master/texmf-dist/tex/latex/l3kernel/l3doc.cls @@ -4,7 +4,8 @@ %% %% The original source files were: %% -%% l3doc.dtx (with options: `class') +%% l3doc.dtx (with options: `class,cfg') +%% %% %% EXPERIMENTAL CODE %% @@ -13,6 +14,7 @@ %% %% Do not distribute a modified version of this file. %% +%% %% File: l3doc.dtx Copyright (C) 1990-2012 The LaTeX3 project %% %% It may be distributed and/or modified under the conditions of the @@ -1457,6 +1459,51 @@ \DisableCrossrefs \OnlyDescription } +\tl_new:N \Team +\tl_set:Nn \Team + { + The~\LaTeX3~Project\thanks + { + Frank~Mittelbach,~Denys~Duchier,~Chris~Rowley,~ + Rainer~Sch\"opf,~Johannes~Braams,~Michael~Downes,~ + David~Carlisle,~Alan~Jeffrey,~Morten~H\o{}gholm,~Thomas~Lotze,~ + Javier~Bezos,~Will~Robertson,~Joseph~Wright,~Bruno~Le~Floch + } + } +\NewDocumentCommand{\ExplMakeTitle}{mm} + { + \title + { + The~\pkg{#1}~package \\ #2 + \thanks + { + This~file~describes~v\ExplFileVersion,~ + last~revised~\ExplFileDate. + } + } + \author + { + The~\LaTeX3~Project\thanks{E-mail:~ + \href{mailto:latex-l@listserv.uni-heidelberg.de} + {latex-l@listserv.uni-heidelberg.de}} + } + \date{Released~\ExplFileDate} + \maketitle + } +\DeclareDocumentCommand\ie{}{\emph{i.e.}} +\DeclareDocumentCommand\eg{}{\emph{e.g.}} +\DeclareDocumentCommand\Ie{}{\emph{I.e.}} +\DeclareDocumentCommand\Eg{}{\emph{E.g.}} +\AtBeginDocument + { + \clist_map_inline:nn + { + asin, acos, atan, acot, + asinh, acosh, atanh, acoth, round, floor, ceil + } + { \exp_args:Nc \DeclareMathOperator{#1}{#1} } + } +\NewDocumentCommand { \nan } { } { \text { \texttt { nan } } } %% %% %% End of file `l3doc.cls'. diff --git a/Master/texmf-dist/tex/latex/l3kernel/l3expan.sty b/Master/texmf-dist/tex/latex/l3kernel/l3expan.sty index 69dc9b3593a..4cfe6746a86 100644 --- a/Master/texmf-dist/tex/latex/l3kernel/l3expan.sty +++ b/Master/texmf-dist/tex/latex/l3kernel/l3expan.sty @@ -46,7 +46,7 @@ %% %% ----------------------------------------------------------------------- \RequirePackage{l3bootstrap} -\GetIdInfo$Id: l3expan.dtx 4521 2013-07-09 11:45:31Z joseph $ +\GetIdInfo$Id: l3expan.dtx 4565 2013-07-24 08:21:51Z joseph $ {L3 Argument expansion} \ProvidesExplPackage {\ExplFileName}{\ExplFileDate}{\ExplFileVersion}{\ExplFileDescription} @@ -501,7 +501,11 @@ \cs_generate_variant:Nn \str_if_eq:nnF { nV , no , VV } \cs_generate_variant:Nn \str_if_eq:nnTF { V , o } \cs_generate_variant:Nn \str_if_eq:nnTF { nV , no , VV } -\cs_generate_variant:Nn \str_case:nnn { o } +\cs_generate_variant:Nn \str_case:nn { o } +\cs_generate_variant:Nn \str_case:nnT { o } +\cs_generate_variant:Nn \str_case:nnF { o } +\cs_generate_variant:Nn \str_case:nnTF { o } +\cs_new_eq:NN \str_case:onn \str_case:onF %% %% %% End of file `l3expan.sty'. diff --git a/Master/texmf-dist/tex/latex/l3kernel/l3file.sty b/Master/texmf-dist/tex/latex/l3kernel/l3file.sty index 16c7c74ede6..35c029411f4 100644 --- a/Master/texmf-dist/tex/latex/l3kernel/l3file.sty +++ b/Master/texmf-dist/tex/latex/l3kernel/l3file.sty @@ -46,7 +46,7 @@ %% %% ----------------------------------------------------------------------- \RequirePackage{l3bootstrap} -\GetIdInfo$Id: l3file.dtx 4483 2013-05-01 10:57:41Z bruno $ +\GetIdInfo$Id: l3file.dtx 4581 2013-07-28 08:38:50Z joseph $ {L3 File and I/O operations} \ProvidesExplPackage {\ExplFileName}{\ExplFileDate}{\ExplFileVersion}{\ExplFileDescription} @@ -543,10 +543,6 @@ Spaces~are~not~permitted~in~files~loaded~by~LaTeX: \\ Further~errors~may~follow! } -\cs_new_eq:NN \ior_to:NN \ior_get:NN -\cs_new_protected_nopar:Npn \ior_gto:NN { \tex_global:D \ior_to:NN } -\cs_new_eq:NN \ior_str_to:NN \ior_get_str:NN -\cs_new_protected_nopar:Npn \ior_str_gto:NN { \tex_global:D \ior_str_to:NN } %% %% %% End of file `l3file.sty'. diff --git a/Master/texmf-dist/tex/latex/l3kernel/l3int.sty b/Master/texmf-dist/tex/latex/l3kernel/l3int.sty index fcff17590c0..7201e626947 100644 --- a/Master/texmf-dist/tex/latex/l3kernel/l3int.sty +++ b/Master/texmf-dist/tex/latex/l3kernel/l3int.sty @@ -46,7 +46,7 @@ %% %% ----------------------------------------------------------------------- \RequirePackage{l3bootstrap} -\GetIdInfo$Id: l3int.dtx 4482 2013-04-24 21:05:12Z joseph $ +\GetIdInfo$Id: l3int.dtx 4581 2013-07-28 08:38:50Z joseph $ {L3 Integers} \ProvidesExplPackage {\ExplFileName}{\ExplFileDate}{\ExplFileVersion}{\ExplFileDescription} @@ -277,13 +277,28 @@ \prg_return_false: \fi: } -\cs_new:Npn \int_case:nnn #1 +\cs_new:Npn \int_case:nnTF #1 { \tex_romannumeral:D - \exp_args:Nf \__int_case:nnn { \int_eval:n {#1} } + \exp_args:Nf \__int_case:nnTF { \int_eval:n {#1} } } -\cs_new:Npn \__int_case:nnn #1#2#3 - { \__int_case:nw {#1} #2 {#1} {#3} \q_recursion_stop } +\cs_new:Npn \int_case:nnT #1#2#3 + { + \tex_romannumeral:D + \exp_args:Nf \__int_case:nnTF { \int_eval:n {#1} } {#2} {#3} { } + } +\cs_new:Npn \int_case:nnF #1#2 + { + \tex_romannumeral:D + \exp_args:Nf \__int_case:nnTF { \int_eval:n {#1} } {#2} { } + } +\cs_new:Npn \int_case:nn #1#2 + { + \tex_romannumeral:D + \exp_args:Nf \__int_case:nnTF { \int_eval:n {#1} } {#2} { } { } + } +\cs_new:Npn \__int_case:nnTF #1#2#3#4 + { \__int_case:nw {#1} #2 {#1} { } \q_mark {#3} \q_mark {#4} \q_stop } \cs_new:Npn \__int_case:nw #1#2#3 { \int_compare:nNnTF {#1} = {#2} @@ -418,13 +433,13 @@ { \exp_args:NNo \exp_args:No \__int_to_symbols:nnnn { - \int_case:nnn + \int_case:nn { 1 + \int_mod:nn { #1 - 1 } {#2} } - {#3} { } + {#3} } {#1} {#2} {#3} } - { \int_case:nnn {#1} {#3} { } } + { \int_case:nn {#1} {#3} } } \cs_new:Npn \__int_to_symbols:nnnn #1#2#3#4 { @@ -777,6 +792,7 @@ \int_new:N \l_tmpb_int \int_new:N \g_tmpa_int \int_new:N \g_tmpb_int +\cs_new_eq:NN \int_case:nnn \int_case:nnF %% %% %% End of file `l3int.sty'. diff --git a/Master/texmf-dist/tex/latex/l3kernel/l3keys.sty b/Master/texmf-dist/tex/latex/l3kernel/l3keys.sty index ab3bf0dcd66..a7a262f3020 100644 --- a/Master/texmf-dist/tex/latex/l3kernel/l3keys.sty +++ b/Master/texmf-dist/tex/latex/l3kernel/l3keys.sty @@ -46,7 +46,7 @@ %% %% ----------------------------------------------------------------------- \RequirePackage{l3bootstrap} -\GetIdInfo$Id: l3keys.dtx 4544 2013-07-12 07:14:52Z joseph $ +\GetIdInfo$Id: l3keys.dtx 4581 2013-07-28 08:38:50Z joseph $ {L3 Experimental key-value interfaces} \ProvidesExplPackage {\ExplFileName}{\ExplFileDate}{\ExplFileVersion}{\ExplFileDescription} @@ -160,19 +160,23 @@ two~equals~signs~not~separated~by~a~comma. } \tl_const:Nn \c__keys_code_root_tl { key~code~>~ } -\tl_const:Nn \c__keys_vars_root_tl { key~var~>~ } +\tl_const:Nn \c__keys_info_root_tl { key~info~>~ } \tl_const:Nn \c__keys_props_root_tl { key~prop~>~ } -\tl_const:Nn \c__keys_value_forbidden_tl { forbidden } -\tl_const:Nn \c__keys_value_required_tl { required } \int_new:N \l_keys_choice_int \tl_new:N \l_keys_choice_tl +\clist_new:N \l__keys_groups_clist \tl_new:N \l_keys_key_tl \tl_new:N \l__keys_module_tl \bool_new:N \l__keys_no_value_bool +\bool_new:N \l__keys_only_known_bool \tl_new:N \l_keys_path_tl \tl_new:N \l__keys_property_tl -\tl_new:N \l__keys_unknown_clist +\bool_new:N \l__keys_selective_bool +\bool_new:N \l__keys_filtered_bool +\seq_new:N \l__keys_selective_seq +\tl_new:N \l__keys_unused_clist \tl_new:N \l_keys_value_tl +\bool_new:N \l__keys_tmp_bool \cs_new_protected:Npn \keys_define:nn { \__keys_define:onn \l__keys_module_tl } \cs_new_protected:Npn \__keys_define:nnn #1#2#3 @@ -302,18 +306,24 @@ } \cs_new_protected:Npn \__keys_cmd_set:nn #1#2 { - \__keys_cmd_set:n {#1} + \prop_clear_new:c { \c__keys_info_root_tl #1 } \cs_set:cpn { \c__keys_code_root_tl #1 } ##1 {#2} } \cs_generate_variant:Nn \__keys_cmd_set:nn { nx , Vn , Vo } -\cs_new_protected:Npn \__keys_cmd_set:n #1 +\cs_new_protected:Npn \__keys_default_set:n #1 { - \tl_clear_new:c { \c__keys_vars_root_tl #1 .default } - \tl_set:cn { \c__keys_vars_root_tl #1 .default } { \q_no_value } - \tl_clear_new:c { \c__keys_vars_root_tl #1 .req } + \prop_if_exist:cT { \c__keys_info_root_tl \l_keys_path_tl } + { \prop_put:cnn { \c__keys_info_root_tl \l_keys_path_tl } { default } {#1} } + } +\cs_new_protected:Npn \__keys_groups_set:n #1 + { + \prop_if_exist:cT { \c__keys_info_root_tl \l_keys_path_tl } + { + \clist_set:Nn \l__keys_groups_clist {#1} + \prop_put:cnV { \c__keys_info_root_tl \l_keys_path_tl } + { groups } \l__keys_groups_clist + } } -\cs_new_protected:Npn \__keys_default_set:n #1 - { \tl_set:cn { \c__keys_vars_root_tl \l_keys_path_tl .default } {#1} } \cs_new_protected:Npn \__keys_initialise:n #1 { \exp_after:wN \__keys_initialise:wn \l_keys_path_tl \q_stop {#1} } \cs_new_protected:Npn \__keys_initialise:wn #1 / #2 \q_stop #3 @@ -355,9 +365,12 @@ } \cs_new_protected:Npn \__keys_value_requirement:n #1 { - \tl_set_eq:cc - { \c__keys_vars_root_tl \l_keys_path_tl .req } - { c__keys_value_ #1 _tl } + \prop_if_exist:cT { \c__keys_info_root_tl \l_keys_path_tl } + { + \prop_remove:cn { \c__keys_info_root_tl \l_keys_path_tl } { required } + \prop_remove:cn { \c__keys_info_root_tl \l_keys_path_tl } { forbidden } + \prop_put:cnn { \c__keys_info_root_tl \l_keys_path_tl } {#1} { true } + } } \cs_new_protected:Npn \__keys_variable_set:NnnN #1#2#3#4 { @@ -426,6 +439,8 @@ { \__keys_variable_set:NnnN #1 { fp } { g } n } \cs_new_protected:cpn { \c__keys_props_root_tl .fp_gset:c } #1 { \__keys_variable_set:cnnN {#1} { fp } { g } n } +\cs_new_protected:cpn { \c__keys_props_root_tl .groups:n } #1 + { \__keys_groups_set:n {#1} } \cs_new_protected:cpn { \c__keys_props_root_tl .initial:n } #1 { \__keys_initialise:n {#1} } \cs_new_protected:cpn { \c__keys_props_root_tl .initial:V } #1 @@ -484,7 +499,7 @@ { \__keys_value_requirement:n { forbidden } } \cs_new_protected_nopar:cpn { \c__keys_props_root_tl .value_required: } { \__keys_value_requirement:n { required } } -\cs_new_protected:Npn \keys_set:nn +\cs_new_protected_nopar:Npn \keys_set:nn { \__keys_set:onn { \l__keys_module_tl } } \cs_new_protected:Npn \__keys_set:nnn #1#2#3 { @@ -494,20 +509,45 @@ } \cs_generate_variant:Nn \keys_set:nn { nV , nv , no } \cs_generate_variant:Nn \__keys_set:nnn { o } -\cs_new_protected:Npn \keys_set_known:nnN - { \__keys_set_known:onnN { \l__keys_module_tl } } -\cs_new_protected:Npn \__keys_set_known:nnnN #1#2#3#4 +\cs_new_protected:Npn \keys_set_known:nnN #1#2#3 { - \tl_set:Nx \l__keys_module_tl { \tl_to_str:n {#2} } - \clist_clear:N \l__keys_unknown_clist - \cs_set_eq:NN \__keys_execute_unknown: \__keys_execute_unknown_alt: - \keyval_parse:NNn \__keys_set_elt:n \__keys_set_elt:nn {#3} - \cs_set_eq:NN \__keys_execute_unknown: \__keys_execute_unknown_std: - \tl_set:Nn \l__keys_module_tl {#1} - \cs_set_eq:NN #4 \l__keys_unknown_clist + \clist_clear:N \l__keys_unused_clist + \keys_set_known:nn {#1} {#2} + \tl_set:Nx #3 { \exp_not:o { \l__keys_unused_clist } } } \cs_generate_variant:Nn \keys_set_known:nnN { nV , nv , no } -\cs_generate_variant:Nn \__keys_set_known:nnnN { o } +\cs_new_protected:Npn \keys_set_known:nn #1#2 + { + \bool_set_true:N \l__keys_only_known_bool + \keys_set:nn {#1} {#2} + \bool_set_false:N \l__keys_only_known_bool + } +\cs_generate_variant:Nn \keys_set_known:nn { nV , nv , no } +\cs_new_protected:Npn \keys_set_filter:nnnN #1#2#3#4 + { + \clist_clear:N \l__keys_unused_clist + \keys_set_filter:nnn {#1} {#2} {#3} + \tl_set:Nx #4 { \exp_not:o { \l__keys_unused_clist } } + } +\cs_generate_variant:Nn \keys_set_filter:nnnN { nnV , nnv , nno } +\cs_new_protected:Npn \keys_set_filter:nnn #1#2#3 + { + \bool_set_true:N \l__keys_selective_bool + \bool_set_true:N \l__keys_filtered_bool + \seq_set_from_clist:Nn \l__keys_selective_seq {#2} + \keys_set:nn {#1} {#3} + \bool_set_false:N \l__keys_selective_bool + } +\cs_generate_variant:Nn \keys_set_filter:nnn { nnV , nnv , nno } +\cs_new_protected:Npn \keys_set_groups:nnn #1#2#3 + { + \bool_set_true:N \l__keys_selective_bool + \bool_set_false:N \l__keys_filtered_bool + \seq_set_from_clist:Nn \l__keys_selective_seq {#2} + \keys_set:nn {#1} {#3} + \bool_set_false:N \l__keys_selective_bool + } +\cs_generate_variant:Nn \keys_set_groups:nnn { nnV , nnv , nno } \cs_new_protected:Npn \__keys_set_elt:n #1 { \bool_set_true:N \l__keys_no_value_bool @@ -523,6 +563,12 @@ \tl_set:Nx \l_keys_key_tl { \tl_to_str:n {#1} } \tl_set:Nx \l_keys_path_tl { \l__keys_module_tl / \l_keys_key_tl } \__keys_value_or_default:n {#2} + \bool_if:NTF \l__keys_selective_bool + { \__keys_set_elt_selective: } + { \__keys_set_elt_aux: } + } +\cs_new_protected_nopar:Npn \__keys_set_elt_aux: + { \bool_if:nTF { \__keys_if_value_p:n { required } && @@ -545,46 +591,83 @@ { \__keys_execute: } } } -\cs_new_protected:Npn \__keys_value_or_default:n #1 +\cs_new_protected_nopar:Npn \__keys_set_elt_selective: + { + \prop_if_exist:cTF { \c__keys_info_root_tl \l_keys_path_tl } + { + \prop_get:cnNTF { \c__keys_info_root_tl \l_keys_path_tl } + { groups } \l__keys_groups_clist + { \__keys_check_groups: } + { + \bool_if:NTF \l__keys_filtered_bool + { \__keys_set_elt_aux: } + { \__keys_store_unused: } + } + } + { + \bool_if:NTF \l__keys_filtered_bool + { \__keys_set_elt_aux: } + { \__keys_store_unused: } + } + } +\cs_new_protected_nopar:Npn \__keys_check_groups: { - \tl_set:Nn \l_keys_value_tl {#1} - \bool_if:NT \l__keys_no_value_bool + \bool_set_false:N \l__keys_tmp_bool + \seq_map_inline:Nn \l__keys_selective_seq { - \quark_if_no_value:cF { \c__keys_vars_root_tl \l_keys_path_tl .default } + \clist_map_inline:Nn \l__keys_groups_clist { - \cs_if_exist:cT { \c__keys_vars_root_tl \l_keys_path_tl .default } + \str_if_eq:nnT {##1} {####1} { - \tl_set_eq:Nc \l_keys_value_tl - { \c__keys_vars_root_tl \l_keys_path_tl .default } + \bool_set_true:N \l__keys_tmp_bool + \clist_map_break:n { \seq_map_break: } } } } + \bool_if:NTF \l__keys_tmp_bool + { + \bool_if:NTF \l__keys_filtered_bool + { \__keys_store_unused: } + { \__keys_set_elt_aux: } + } + { + \bool_if:NTF \l__keys_filtered_bool + { \__keys_set_elt_aux: } + { \__keys_store_unused: } + } + } +\cs_new_protected:Npn \__keys_value_or_default:n #1 + { + \bool_if:NTF \l__keys_no_value_bool + { + \prop_get:cnNF { \c__keys_info_root_tl \l_keys_path_tl } + { default } \l_keys_value_tl + { \tl_clear:N \l_keys_value_tl } + } + { \tl_set:Nn \l_keys_value_tl {#1} } } \prg_new_conditional:Npnn \__keys_if_value:n #1 { p } { - \tl_if_eq:ccTF { c__keys_value_ #1 _tl } - { \c__keys_vars_root_tl \l_keys_path_tl .req } - { \prg_return_true: } + \prop_if_exist:cTF { \c__keys_info_root_tl \l_keys_path_tl } + { + \prop_if_in:cnTF { \c__keys_info_root_tl \l_keys_path_tl } {#1} + { \prg_return_true: } + { \prg_return_false: } + } { \prg_return_false: } } \cs_new_protected_nopar:Npn \__keys_execute: { \__keys_execute:nn { \l_keys_path_tl } { \__keys_execute_unknown: } } \cs_new_protected_nopar:Npn \__keys_execute_unknown: { - \__keys_execute:nn { \l__keys_module_tl / unknown } + \bool_if:NTF \l__keys_only_known_bool + { \__keys_store_unused: } { - \__msg_kernel_error:nnxx { kernel } { key-unknown } - { \l_keys_path_tl } { \l__keys_module_tl } - } - } -\cs_new_eq:NN \__keys_execute_unknown_std: \__keys_execute_unknown: -\cs_new_protected_nopar:Npn \__keys_execute_unknown_alt: - { - \clist_put_right:Nx \l__keys_unknown_clist - { - \exp_not:o \l_keys_key_tl - \bool_if:NF \l__keys_no_value_bool - { = { \exp_not:o \l_keys_value_tl } } + \__keys_execute:nn { \l__keys_module_tl / unknown } + { + \__msg_kernel_error:nnxx { kernel } { key-unknown } + { \l_keys_path_tl } { \l__keys_module_tl } + } } } \cs_new:Npn \__keys_execute:nn #1#2 @@ -596,6 +679,15 @@ } {#2} } +\cs_new_protected_nopar:Npn \__keys_store_unused: + { + \clist_put_right:Nx \l__keys_unused_clist + { + \exp_not:o \l_keys_key_tl + \bool_if:NF \l__keys_no_value_bool + { = { \exp_not:o \l_keys_value_tl } } + } + } \cs_new:Npn \__keys_choice_find:n #1 { \__keys_execute:nn { \l_keys_path_tl / \tl_to_str:n {#1} } @@ -673,12 +765,12 @@ \cs_new_protected:Npn \__keys_choice_code_store:n #1 { \cs_if_exist:cF - { \c__keys_vars_root_tl \l_keys_path_tl .choice~code } + { \c__keys_info_root_tl \l_keys_path_tl .choice~code } { \tl_new:c - { \c__keys_vars_root_tl \l_keys_path_tl .choice~code } + { \c__keys_info_root_tl \l_keys_path_tl .choice~code } } - \tl_set:cn { \c__keys_vars_root_tl \l_keys_path_tl .choice~code } + \tl_set:cn { \c__keys_info_root_tl \l_keys_path_tl .choice~code } {#1} } \cs_generate_variant:Nn \__keys_choice_code_store:n { x } @@ -689,7 +781,7 @@ \cs_new_protected:Npn \__keys_choices_generate:n #1 { \cs_if_exist:cTF - { \c__keys_vars_root_tl \l_keys_path_tl .choice~code } + { \c__keys_info_root_tl \l_keys_path_tl .choice~code } { \__keys_choice_make: \int_zero:N \l_keys_choice_int @@ -709,7 +801,7 @@ \int_set:Nn \exp_not:N \l_keys_choice_int { \int_use:N \l_keys_choice_int } \exp_not:v - { \c__keys_vars_root_tl \l_keys_path_tl .choice~code } + { \c__keys_info_root_tl \l_keys_path_tl .choice~code } } } \__msg_kernel_new:nnnn { kernel } { generate-choices-before-code } diff --git a/Master/texmf-dist/tex/latex/l3kernel/l3luatex.sty b/Master/texmf-dist/tex/latex/l3kernel/l3luatex.sty index 9673e80ab1c..74d3875a445 100644 --- a/Master/texmf-dist/tex/latex/l3kernel/l3luatex.sty +++ b/Master/texmf-dist/tex/latex/l3kernel/l3luatex.sty @@ -13,7 +13,7 @@ %% %% Do not distribute a modified version of this file. %% -%% File: l3luatex.dtx Copyright (C) 2010-2012 The LaTeX3 Project +%% File: l3luatex.dtx Copyright (C) 2010-2013 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 @@ -46,7 +46,7 @@ %% %% ----------------------------------------------------------------------- \RequirePackage{l3bootstrap} -\GetIdInfo$Id: l3luatex.dtx 4049 2012-08-03 14:01:40Z bruno $ +\GetIdInfo$Id: l3luatex.dtx 4581 2013-07-28 08:38:50Z joseph $ {L3 Experimental LuaTeX-specific functions} \ProvidesExplPackage {\ExplFileName}{\ExplFileDate}{\ExplFileVersion}{\ExplFileDescription} diff --git a/Master/texmf-dist/tex/latex/l3kernel/l3msg.sty b/Master/texmf-dist/tex/latex/l3kernel/l3msg.sty index 5ceb1e0e81c..fd4541915c4 100644 --- a/Master/texmf-dist/tex/latex/l3kernel/l3msg.sty +++ b/Master/texmf-dist/tex/latex/l3kernel/l3msg.sty @@ -46,7 +46,7 @@ %% %% ----------------------------------------------------------------------- \RequirePackage{l3bootstrap} -\GetIdInfo$Id: l3msg.dtx 4412 2013-01-08 12:23:19Z joseph $ +\GetIdInfo$Id: l3msg.dtx 4581 2013-07-28 08:38:50Z joseph $ {L3 Messages} \ProvidesExplPackage {\ExplFileName}{\ExplFileDate}{\ExplFileVersion}{\ExplFileDescription} @@ -642,6 +642,8 @@ { Erroneous~variable~#1 used! } \__msg_kernel_new:nnn { kernel } { misused-sequence } { A~sequence~was~misused. } +\__msg_kernel_new:nnn { kernel } { misused-prop } + { A~property~list~was~misused. } \__msg_kernel_new:nnn { kernel } { negative-replication } { Negative~argument~for~\prg_replicate:nn. } \__msg_kernel_new:nnn { kernel } { unknown-comparison } diff --git a/Master/texmf-dist/tex/latex/l3kernel/l3prg.sty b/Master/texmf-dist/tex/latex/l3kernel/l3prg.sty index 8bc31c71ee5..bf730fd44cc 100644 --- a/Master/texmf-dist/tex/latex/l3kernel/l3prg.sty +++ b/Master/texmf-dist/tex/latex/l3kernel/l3prg.sty @@ -46,7 +46,7 @@ %% %% ----------------------------------------------------------------------- \RequirePackage{l3bootstrap} -\GetIdInfo$Id: l3prg.dtx 4482 2013-04-24 21:05:12Z joseph $ +\GetIdInfo$Id: l3prg.dtx 4581 2013-07-28 08:38:50Z joseph $ {L3 Control structures} %% \ProvidesExplPackage diff --git a/Master/texmf-dist/tex/latex/l3kernel/l3prop.sty b/Master/texmf-dist/tex/latex/l3kernel/l3prop.sty index 85cff451ddb..c08682a0b57 100644 --- a/Master/texmf-dist/tex/latex/l3kernel/l3prop.sty +++ b/Master/texmf-dist/tex/latex/l3kernel/l3prop.sty @@ -46,24 +46,34 @@ %% %% ----------------------------------------------------------------------- \RequirePackage{l3bootstrap} -\GetIdInfo$Id: l3prop.dtx 4423 2013-01-09 00:05:30Z bruno $ +\GetIdInfo$Id: l3prop.dtx 4581 2013-07-28 08:38:50Z joseph $ {L3 Property lists} \ProvidesExplPackage {\ExplFileName}{\ExplFileDate}{\ExplFileVersion}{\ExplFileDescription} \__expl_package_check: \__scan_new:N \s__prop +\cs_new:Npn \__prop_pair:wn #1 \s__prop #2 + { \__msg_kernel_expandable_error:nn { kernel } { misused-prop } } \tl_new:N \l__prop_internal_tl -\cs_new_eq:NN \c_empty_prop \c_empty_tl -\cs_new_eq:NN \prop_new:N \tl_new:N -\cs_new_eq:NN \prop_new:c \tl_new:c -\cs_new_eq:NN \prop_clear:N \tl_clear:N -\cs_new_eq:NN \prop_clear:c \tl_clear:c -\cs_new_eq:NN \prop_gclear:N \tl_gclear:N -\cs_new_eq:NN \prop_gclear:c \tl_gclear:c -\cs_new_eq:NN \prop_clear_new:N \tl_clear_new:N -\cs_new_eq:NN \prop_clear_new:c \tl_clear_new:c -\cs_new_eq:NN \prop_gclear_new:N \tl_gclear_new:N -\cs_new_eq:NN \prop_gclear_new:c \tl_gclear_new:c +\tl_const:Nn \c_empty_prop { \s__prop \s_obj_end } +\cs_new_protected:Npn \prop_new:N #1 + { + \__chk_if_free_cs:N #1 + \cs_gset_eq:NN #1 \c_empty_prop + } +\cs_generate_variant:Nn \prop_new:N { c } +\cs_new_protected:Npn \prop_clear:N #1 + { \prop_set_eq:NN #1 \c_empty_prop } +\cs_generate_variant:Nn \prop_clear:N { c } +\cs_new_protected:Npn \prop_gclear:N #1 + { \prop_gset_eq:NN #1 \c_empty_prop } +\cs_generate_variant:Nn \prop_gclear:N { c } +\cs_new_protected:Npn \prop_clear_new:N #1 + { \prop_if_exist:NTF #1 { \prop_clear:N #1 } { \prop_new:N #1 } } +\cs_generate_variant:Nn \prop_clear_new:N { c } +\cs_new_protected:Npn \prop_gclear_new:N #1 + { \prop_if_exist:NTF #1 { \prop_gclear:N #1 } { \prop_new:N #1 } } +\cs_generate_variant:Nn \prop_gclear_new:N { c } \cs_new_eq:NN \prop_set_eq:NN \tl_set_eq:NN \cs_new_eq:NN \prop_set_eq:Nc \tl_set_eq:Nc \cs_new_eq:NN \prop_set_eq:cN \tl_set_eq:cN @@ -76,15 +86,16 @@ \prop_new:N \l_tmpb_prop \prop_new:N \g_tmpa_prop \prop_new:N \g_tmpb_prop +\cs_new:Npn \__prop_strip_end:w #1 \s_obj_end { \exp_not:n {#1} } \cs_new_protected:Npn \__prop_split:NnTF #1#2 { \exp_args:NNo \__prop_split_aux:NnTF #1 { \tl_to_str:n {#2} } } \cs_new_protected:Npn \__prop_split_aux:NnTF #1#2#3#4 { \cs_set:Npn \__prop_split_aux:w ##1 - \s__prop #2 \s__prop ##2 ##3 \q_mark ##4 ##5 \q_stop + \__prop_pair:wn #2 \s__prop ##2 ##3 \q_mark ##4 ##5 \q_stop { ##4 {#3} {#4} } \exp_after:wN \__prop_split_aux:w #1 \q_mark \use_i:nn - \s__prop #2 \s__prop { } \q_mark \use_ii:nn \q_stop + \__prop_pair:wn #2 \s__prop { } \q_mark \use_ii:nn \q_stop } \cs_new:Npn \__prop_split_aux:w { } \cs_new_protected:Npn \prop_remove:Nn #1#2 @@ -159,17 +170,24 @@ \cs_generate_variant:Nn \prop_gpop:NnNT { c } \cs_generate_variant:Nn \prop_gpop:NnNF { c } \cs_generate_variant:Nn \prop_gpop:NnNTF { c } -\cs_new_protected_nopar:Npn \prop_put:Nnn - { \__prop_put:NNNnn \tl_set:Nx \tl_put_right:Nx } -\cs_new_protected_nopar:Npn \prop_gput:Nnn - { \__prop_put:NNNnn \tl_gset:Nx \tl_gput_right:Nx } -\cs_new_protected:Npn \__prop_put:NNNnn #1#2#3#4#5 +\cs_new_protected_nopar:Npn \prop_put:Nnn { \__prop_put:NNnn \tl_set:Nx } +\cs_new_protected_nopar:Npn \prop_gput:Nnn { \__prop_put:NNnn \tl_gset:Nx } +\cs_new_protected:Npn \__prop_put:NNnn #1#2#3#4 { \tl_set:Nn \l__prop_internal_tl - { \s__prop \tl_to_str:n {#4} \s__prop { \exp_not:n {#5} } } - \__prop_split:NnTF #3 {#4} - { #1 #3 { \exp_not:n {##1} \l__prop_internal_tl \exp_not:n {##3} } } - { #2 #3 { \l__prop_internal_tl } } + { + \exp_not:N \__prop_pair:wn \tl_to_str:n {#3} + \s__prop { \exp_not:n {#4} } + } + \__prop_split:NnTF #2 {#3} + { #1 #2 { \exp_not:n {##1} \l__prop_internal_tl \exp_not:n {##3} } } + { + #1 #2 + { + \exp_after:wN \__prop_strip_end:w #2 + \l__prop_internal_tl \s_obj_end + } + } } \cs_generate_variant:Nn \prop_put:Nnn { NnV , Nno , Nnx , NV , NVV , No , Noo } @@ -180,45 +198,58 @@ \cs_generate_variant:Nn \prop_gput:Nnn { c , cnV , cno , cnx , cV , cVV , co , coo } \cs_new_protected_nopar:Npn \prop_put_if_new:Nnn - { \__prop_put_if_new:NNnn \tl_put_right:Nx } + { \__prop_put_if_new:NNnn \tl_set:Nx } \cs_new_protected_nopar:Npn \prop_gput_if_new:Nnn - { \__prop_put_if_new:NNnn \tl_gput_right:Nx } + { \__prop_put_if_new:NNnn \tl_gset:Nx } \cs_new_protected:Npn \__prop_put_if_new:NNnn #1#2#3#4 { \tl_set:Nn \l__prop_internal_tl - { \s__prop \tl_to_str:n {#3} \s__prop \exp_not:n { {#4} } } + { + \exp_not:N \__prop_pair:wn \tl_to_str:n {#3} + \s__prop \exp_not:n { {#4} } + } \__prop_split:NnTF #2 {#3} { } - { #1 #2 { \l__prop_internal_tl } } + { + #1 #2 + { + \exp_after:wN \__prop_strip_end:w #2 + \l__prop_internal_tl \s_obj_end + } + } } \cs_generate_variant:Nn \prop_put_if_new:Nnn { c } \cs_generate_variant:Nn \prop_gput_if_new:Nnn { c } \prg_new_eq_conditional:NNn \prop_if_exist:N \cs_if_exist:N { TF , T , F , p } \prg_new_eq_conditional:NNn \prop_if_exist:c \cs_if_exist:c { TF , T , F , p } -\prg_new_eq_conditional:NNn \prop_if_empty:N \tl_if_empty:N - { p , T , F , TF } -\prg_new_eq_conditional:NNn \prop_if_empty:c \tl_if_empty:c - { p , T , F , TF } +\prg_new_conditional:Npnn \prop_if_empty:N #1 { p , T , F , TF } + { + \tl_if_eq:NNTF #1 \c_empty_prop + \prg_return_true: \prg_return_false: + } +\cs_generate_variant:Nn \prop_if_empty_p:N { c } +\cs_generate_variant:Nn \prop_if_empty:NT { c } +\cs_generate_variant:Nn \prop_if_empty:NF { c } +\cs_generate_variant:Nn \prop_if_empty:NTF { c } \prg_new_conditional:Npnn \prop_if_in:Nn #1#2 { p , T , F , TF } { - \exp_last_unbraced:Noo \__prop_if_in:nwn - { \tl_to_str:n {#2} } #1 - \s__prop \tl_to_str:n {#2} \s__prop { } - \q_recursion_tail + \exp_last_unbraced:Noo \__prop_if_in:nwwn { \tl_to_str:n {#2} } #1 + \__prop_pair:wn \tl_to_str:n {#2} \s__prop { } + \q_recursion_tail \__prg_break_point: } -\cs_new:Npn \__prop_if_in:nwn #1 \s__prop #2 \s__prop #3 +\cs_new:Npn \__prop_if_in:nwwn #1#2 \__prop_pair:wn #3 \s__prop #4 { - \str_if_eq_x:nnTF {#1} {#2} + \str_if_eq_x:nnTF {#1} {#3} { \__prop_if_in:N } - { \__prop_if_in:nwn {#1} } + { \__prop_if_in:nwwn {#1} } } \cs_new:Npn \__prop_if_in:N #1 { - \if_meaning:w \s__prop #1 - \prg_return_true: - \else: + \if_meaning:w \q_recursion_tail #1 \prg_return_false: + \else: + \prg_return_true: \fi: \__prg_break: } @@ -247,29 +278,33 @@ \cs_generate_variant:Nn \prop_get:NnNTF { c , cV , co } \cs_new:Npn \prop_map_function:NN #1#2 { - \exp_last_unbraced:NNo \__prop_map_function:Nwn #2 - #1 \s__prop \q_recursion_tail \s__prop { } + \exp_last_unbraced:NNo \__prop_map_function:Nwwn #2 #1 + \__prop_pair:wn \q_recursion_tail \s__prop { } \__prg_break_point:Nn \prop_map_break: { } } -\cs_new:Npn \__prop_map_function:Nwn #1 \s__prop #2 \s__prop #3 +\cs_new:Npn \__prop_map_function:Nwwn #1#2 \__prop_pair:wn #3 \s__prop #4 { - \if_meaning:w \q_recursion_tail #2 + \if_meaning:w \q_recursion_tail #3 \exp_after:wN \prop_map_break: \fi: - #1 {#2} {#3} - \__prop_map_function:Nwn #1 + #1 {#3} {#4} + \__prop_map_function:Nwwn #1 } \cs_generate_variant:Nn \prop_map_function:NN { Nc } \cs_generate_variant:Nn \prop_map_function:NN { c , cc } \cs_new_protected:Npn \prop_map_inline:Nn #1#2 { + \cs_gset_eq:cN + { __prg_map_ \int_use:N \g__prg_map_int :wn } \__prop_pair:wn \int_gincr:N \g__prg_map_int - \cs_gset:cpn { __prg_map_ \int_use:N \g__prg_map_int :w } ##1##2 {#2} - \exp_last_unbraced:Nco \__prop_map_function:Nwn - { __prg_map_ \int_use:N \g__prg_map_int :w } - #1 - \s__prop \q_recursion_tail \s__prop { } - \__prg_break_point:Nn \prop_map_break: { \int_gdecr:N \g__prg_map_int } + \cs_gset:Npn \__prop_pair:wn ##1 \s__prop ##2 {#2} + #1 + \__prg_break_point:Nn \prop_map_break: + { + \int_gdecr:N \g__prg_map_int + \cs_gset_eq:Nc \__prop_pair:wn + { __prg_map_ \int_use:N \g__prg_map_int :wn } + } } \cs_generate_variant:Nn \prop_map_inline:Nn { c } \cs_new_nopar:Npn \prop_map_break: diff --git a/Master/texmf-dist/tex/latex/l3kernel/l3quark.sty b/Master/texmf-dist/tex/latex/l3kernel/l3quark.sty index 46447aae9a1..6f13a54607b 100644 --- a/Master/texmf-dist/tex/latex/l3kernel/l3quark.sty +++ b/Master/texmf-dist/tex/latex/l3kernel/l3quark.sty @@ -46,7 +46,7 @@ %% %% ----------------------------------------------------------------------- \RequirePackage{l3bootstrap} -\GetIdInfo$Id: l3quark.dtx 4521 2013-07-09 11:45:31Z joseph $ +\GetIdInfo$Id: l3quark.dtx 4564 2013-07-21 02:12:33Z bruno $ {L3 Quarks} \ProvidesExplPackage {\ExplFileName}{\ExplFileDate}{\ExplFileVersion}{\ExplFileDescription} @@ -162,6 +162,8 @@ } \__scan_new:N \s__stop \cs_new:Npn \__use_none_delimit_by_s__stop:w #1 \s__stop { } +\__scan_new:N \s__seq +\__scan_new:N \s_obj_end \cs_new:Npn \quark_if_recursion_tail_break:N #1 { \__quark_if_recursion_tail_break:NN #1 \prg_break: } \cs_new:Npn \quark_if_recursion_tail_break:n #1 diff --git a/Master/texmf-dist/tex/latex/l3kernel/l3seq.sty b/Master/texmf-dist/tex/latex/l3kernel/l3seq.sty index 80ee168e421..2df60faf409 100644 --- a/Master/texmf-dist/tex/latex/l3kernel/l3seq.sty +++ b/Master/texmf-dist/tex/latex/l3kernel/l3seq.sty @@ -46,7 +46,7 @@ %% %% ----------------------------------------------------------------------- \RequirePackage{l3bootstrap} -\GetIdInfo$Id: l3seq.dtx 4500 2013-05-26 11:18:19Z bruno $ +\GetIdInfo$Id: l3seq.dtx 4581 2013-07-28 08:38:50Z joseph $ {L3 Sequences and stacks} \ProvidesExplPackage {\ExplFileName}{\ExplFileDate}{\ExplFileVersion}{\ExplFileDescription} @@ -58,17 +58,25 @@ } \tl_new:N \l__seq_internal_a_tl \tl_new:N \l__seq_internal_b_tl -\cs_new_eq:NN \c_empty_seq \c_empty_tl -\cs_new_eq:NN \seq_new:N \tl_new:N -\cs_new_eq:NN \seq_new:c \tl_new:c -\cs_new_eq:NN \seq_clear:N \tl_clear:N -\cs_new_eq:NN \seq_clear:c \tl_clear:c -\cs_new_eq:NN \seq_gclear:N \tl_gclear:N -\cs_new_eq:NN \seq_gclear:c \tl_gclear:c -\cs_new_eq:NN \seq_clear_new:N \tl_clear_new:N -\cs_new_eq:NN \seq_clear_new:c \tl_clear_new:c -\cs_new_eq:NN \seq_gclear_new:N \tl_gclear_new:N -\cs_new_eq:NN \seq_gclear_new:c \tl_gclear_new:c +\tl_const:Nn \c_empty_seq { \s__seq \s_obj_end } +\cs_new_protected:Npn \seq_new:N #1 + { + \__chk_if_free_cs:N #1 + \cs_gset_eq:NN #1 \c_empty_seq + } +\cs_generate_variant:Nn \seq_new:N { c } +\cs_new_protected:Npn \seq_clear:N #1 + { \seq_set_eq:NN #1 \c_empty_seq } +\cs_generate_variant:Nn \seq_clear:N { c } +\cs_new_protected:Npn \seq_gclear:N #1 + { \seq_gset_eq:NN #1 \c_empty_seq } +\cs_generate_variant:Nn \seq_gclear:N { c } +\cs_new_protected:Npn \seq_clear_new:N #1 + { \seq_if_exist:NTF #1 { \seq_clear:N #1 } { \seq_new:N #1 } } +\cs_generate_variant:Nn \seq_clear_new:N { c } +\cs_new_protected:Npn \seq_gclear_new:N #1 + { \seq_if_exist:NTF #1 { \seq_gclear:N #1 } { \seq_new:N #1 } } +\cs_generate_variant:Nn \seq_gclear_new:N { c } \cs_new_eq:NN \seq_set_eq:NN \tl_set_eq:NN \cs_new_eq:NN \seq_set_eq:Nc \tl_set_eq:Nc \cs_new_eq:NN \seq_set_eq:cN \tl_set_eq:cN @@ -81,10 +89,13 @@ { \__seq_set_split:NNnn \tl_set:Nx } \cs_new_protected_nopar:Npn \seq_gset_split:Nnn { \__seq_set_split:NNnn \tl_gset:Nx } -\cs_new_protected:Npn \__seq_set_split:NNnn #1 #2 #3 #4 +\cs_new_protected:Npn \__seq_set_split:NNnn #1#2#3#4 { \tl_if_empty:nTF {#3} - { #1 #2 { \tl_map_function:nN {#4} \__seq_wrap_item:n } } + { + \tl_set:Nn \l__seq_internal_a_tl + { \tl_map_function:nN {#4} \__seq_wrap_item:n } + } { \tl_set:Nn \l__seq_internal_a_tl { @@ -98,8 +109,8 @@ \__seq_set_split_auxi:w \prg_do_nothing: } \tl_set:Nx \l__seq_internal_a_tl { \l__seq_internal_a_tl } - #1 #2 { \l__seq_internal_a_tl } } + #1 #2 { \s__seq \l__seq_internal_a_tl \s_obj_end } } \cs_new:Npn \__seq_set_split_auxi:w #1 \__seq_set_split_end: { @@ -111,28 +122,58 @@ { \__seq_wrap_item:n {#1} } \cs_generate_variant:Nn \seq_set_split:Nnn { NnV } \cs_generate_variant:Nn \seq_gset_split:Nnn { NnV } -\cs_new_eq:NN \seq_concat:NNN \tl_concat:NNN -\cs_new_eq:NN \seq_gconcat:NNN \tl_gconcat:NNN -\cs_new_eq:NN \seq_concat:ccc \tl_concat:ccc -\cs_new_eq:NN \seq_gconcat:ccc \tl_gconcat:ccc +\cs_new_protected:Npn \seq_concat:NNN #1#2#3 + { \tl_set:Nf #1 { \exp_last_unbraced:NNo \__seq_concat:NN #2 #3 } } +\cs_new_protected:Npn \seq_gconcat:NNN #1#2#3 + { \tl_gset:Nf #1 { \exp_last_unbraced:NNo \__seq_concat:NN #2 #3 } } +\cs_new:Npn \__seq_concat:NN #1#2 { \exp_after:wN \__seq_concat:w #1 } +\cs_new:Npn \__seq_concat:w #1 \s_obj_end {#1} +\cs_generate_variant:Nn \seq_concat:NNN { ccc } +\cs_generate_variant:Nn \seq_gconcat:NNN { ccc } \prg_new_eq_conditional:NNn \seq_if_exist:N \cs_if_exist:N { TF , T , F , p } \prg_new_eq_conditional:NNn \seq_if_exist:c \cs_if_exist:c { TF , T , F , p } \cs_new_protected:Npn \seq_put_left:Nn #1#2 - { \tl_put_left:Nn #1 { \__seq_item:n {#2} } } -\cs_new_protected:Npn \seq_put_right:Nn #1#2 - { \tl_put_right:Nn #1 { \__seq_item:n {#2} } } + { + \tl_set:Nx #1 + { + \exp_not:n { \s__seq \__seq_item:n {#2} } + \exp_not:f { \exp_after:wN \__seq_put_left_aux:w #1 } + } + } +\cs_new_protected:Npn \seq_gput_left:Nn #1#2 + { + \tl_gset:Nx #1 + { + \exp_not:n { \s__seq \__seq_item:n {#2} } + \exp_not:f { \exp_after:wN \__seq_put_left_aux:w #1 } + } + } +\cs_new:Npn \__seq_put_left_aux:w \s__seq { \exp_stop_f: } \cs_generate_variant:Nn \seq_put_left:Nn { NV , Nv , No , Nx } \cs_generate_variant:Nn \seq_put_left:Nn { c , cV , cv , co , cx } -\cs_generate_variant:Nn \seq_put_right:Nn { NV , Nv , No , Nx } -\cs_generate_variant:Nn \seq_put_right:Nn { c , cV , cv , co , cx } -\cs_new_protected:Npn \seq_gput_left:Nn #1#2 - { \tl_gput_left:Nn #1 { \__seq_item:n {#2} } } -\cs_new_protected:Npn \seq_gput_right:Nn #1#2 - { \tl_gput_right:Nn #1 { \__seq_item:n {#2} } } \cs_generate_variant:Nn \seq_gput_left:Nn { NV , Nv , No , Nx } \cs_generate_variant:Nn \seq_gput_left:Nn { c , cV , cv , co , cx } +\cs_new_protected:Npn \seq_put_right:Nn #1#2 + { + \tl_set:Nx #1 + { + \exp_after:wN \__seq_put_right_aux:w #1 + \exp_not:n { \__seq_item:n {#2} \s_obj_end } + } + } +\cs_new_protected:Npn \seq_gput_right:Nn #1#2 + { + \tl_gset:Nx #1 + { + \exp_after:wN \__seq_put_right_aux:w #1 + \exp_not:n { \__seq_item:n {#2} \s_obj_end } + } + } +\cs_new:Npn \__seq_put_right_aux:w #1 \s_obj_end { \exp_not:n {#1} } \cs_generate_variant:Nn \seq_gput_right:Nn { NV , Nv , No , Nx } \cs_generate_variant:Nn \seq_gput_right:Nn { c , cV , cv , co , cx } +\cs_generate_variant:Nn \seq_put_right:Nn { NV , Nv , No , Nx } +\cs_generate_variant:Nn \seq_put_right:Nn { c , cV , cv , co , cx } \cs_new:Npn \__seq_wrap_item:n #1 { \exp_not:n { \__seq_item:n {#1} } } \seq_new:N \l__seq_remove_seq \cs_new_protected:Npn \seq_remove_duplicates:N @@ -177,10 +218,18 @@ } \cs_generate_variant:Nn \seq_remove_all:Nn { c } \cs_generate_variant:Nn \seq_gremove_all:Nn { c } -\prg_new_eq_conditional:NNn \seq_if_empty:N \tl_if_empty:N - { p , T , F , TF } -\prg_new_eq_conditional:NNn \seq_if_empty:c \tl_if_empty:c - { p , T , F , TF } +\prg_new_conditional:Npnn \seq_if_empty:N #1 { p , T , F , TF } + { + \if_meaning:w #1 \c_empty_seq + \prg_return_true: + \else: + \prg_return_false: + \fi: + } +\cs_generate_variant:Nn \seq_if_empty_p:N { c } +\cs_generate_variant:Nn \seq_if_empty:NT { c } +\cs_generate_variant:Nn \seq_if_empty:NF { c } +\cs_generate_variant:Nn \seq_if_empty:NTF { c } \prg_new_protected_conditional:Npnn \seq_if_in:Nn #1#2 { T , F , TF } { @@ -228,30 +277,33 @@ { \tl_set:Nx #2 { - \exp_after:wN \__seq_get_left:Nnw + \exp_after:wN \__seq_get_left:wnw #1 \__seq_item:n { \q_no_value } \q_stop } } -\cs_new:Npn \__seq_get_left:Nnw \__seq_item:n #1#2 \q_stop - { \exp_not:n {#1} } +\cs_new:Npn \__seq_get_left:wnw #1 \__seq_item:n #2#3 \q_stop + { \exp_not:n {#2} } \cs_generate_variant:Nn \seq_get_left:NN { c } \cs_new_protected_nopar:Npn \seq_pop_left:NN { \__seq_pop:NNNN \__seq_pop_left:NNN \tl_set:Nn } \cs_new_protected_nopar:Npn \seq_gpop_left:NN { \__seq_pop:NNNN \__seq_pop_left:NNN \tl_gset:Nn } \cs_new_protected:Npn \__seq_pop_left:NNN #1#2#3 - { \exp_after:wN \__seq_pop_left:NnwNNN #2 \q_stop #1#2#3 } -\cs_new_protected:Npn \__seq_pop_left:NnwNNN \__seq_item:n #1#2 \q_stop #3#4#5 + { \exp_after:wN \__seq_pop_left:wnwNNN #2 \q_stop #1#2#3 } +\cs_new_protected:Npn \__seq_pop_left:wnwNNN + #1 \__seq_item:n #2#3 \q_stop #4#5#6 { - #3 #4 {#2} - \tl_set:Nn #5 {#1} + #4 #5 { #1 #3 } + \tl_set:Nn #6 {#2} } \cs_generate_variant:Nn \seq_pop_left:NN { c } \cs_generate_variant:Nn \seq_gpop_left:NN { c } \cs_new_protected:Npn \seq_get_right:NN #1#2 + { \exp_after:wN \__seq_get_right_setup:wN #1 #2 } +\cs_new_protected:Npn \__seq_get_right_setup:wN \s__seq #1 \s_obj_end #2 { - \exp_after:wN \__seq_get_right_loop:nn - \exp_after:wN \q_no_value + \__seq_get_right_loop:nn + \q_no_value #1 { ?? @@ -274,18 +326,18 @@ \cs_set_eq:NN \seq_tmp:w \__seq_item:n \cs_set_eq:NN \__seq_item:n \scan_stop: #1 #2 - { \if_false: } \fi: - \exp_after:wN \exp_after:wN - \exp_after:wN \__seq_pop_right_loop:nn - \exp_after:wN \use_none:n + { \if_false: } \fi: \s__seq + \exp_after:wN \__seq_pop_right_setup:w #2 { - \if_false: { \fi: } + \s_obj_end \if_false: { \fi: } \tex_afterassignment:D \use_none:n \tl_set:Nx #3 } \cs_set_eq:NN \__seq_item:n \seq_tmp:w } +\cs_new:Npn \__seq_pop_right_setup:w \s__seq #1 \s_obj_end + { \exp_after:wN \__seq_pop_right_loop:nn \use_none:n #1 } \cs_new:Npn \__seq_pop_right_loop:nn #1#2 { #2 { \exp_not:n {#1} } @@ -328,9 +380,10 @@ \cs_new_nopar:Npn \seq_map_break:n { \__prg_map_break:Nn \seq_map_break: } \cs_new:Npn \seq_map_function:NN #1#2 + { \exp_after:wN \__seq_map_function:wN #1 #2 } +\cs_new:Npn \__seq_map_function:wN \s__seq #1 \s_obj_end #2 { - \exp_after:wN \__seq_map_function:NNn \exp_after:wN #2 #1 - { ? \seq_map_break: } { } + \__seq_map_function:NNn #2 #1 { ? \seq_map_break: } { } \__prg_break_point:Nn \seq_map_break: { } } \cs_new:Npn \__seq_map_function:NNn #1#2#3 @@ -395,15 +448,18 @@ { \seq_if_exist:NTF #1 { - \int_case:nnn { \seq_count:N #1 } + \int_case:nnF { \seq_count:N #1 } { { 0 } { } - { 1 } { \exp_after:wN \__seq_use:NnNnn #1 \__seq_item:n { } { } } - { 2 } { \exp_after:wN \__seq_use:NnNnn #1 {#2} } + { 1 } + { + \exp_after:wN \__seq_use:wnwnn #1 + \__seq_item:n { } \s_obj_end { } + } + { 2 } { \exp_after:wN \__seq_use:wnwnn #1 {#2} } } { - \exp_after:wN \__seq_use:nwwwwnwn - \exp_after:wN { \exp_after:wN } #1 \__seq_item:n + \exp_after:wN \__seq_use_setup:w #1 \__seq_item:n \q_mark { \__seq_use:nwwwwnwn {#3} } \q_mark { \__seq_use:nwwn {#4} } \q_stop { } @@ -412,8 +468,11 @@ { \__msg_kernel_expandable_error:nnn { kernel } { bad-variable } {#1} } } \cs_generate_variant:Nn \seq_use:Nnnn { c } -\cs_new:Npn \__seq_use:NnNnn \__seq_item:n #1 \__seq_item:n #2#3 - { \exp_not:n { #1 #3 #2 } } +\cs_new:Npn \__seq_use:wnwnn + #1 \__seq_item:n #2#3 \__seq_item:n #4#5 \s_obj_end #6 + { \exp_not:n { #2 #6 #4 } } +\cs_new:Npn \__seq_use_setup:w \s__seq #1 \s_obj_end + { \__seq_use:nwwwwnwn { } #1 } \cs_new:Npn \__seq_use:nwwwwnwn #1 \__seq_item:n #2 \__seq_item:n #3 \__seq_item:n #4#5 \q_mark #6#7 \q_stop #8 diff --git a/Master/texmf-dist/tex/latex/l3kernel/l3skip.sty b/Master/texmf-dist/tex/latex/l3kernel/l3skip.sty index 20f3c09ebcd..419536abeab 100644 --- a/Master/texmf-dist/tex/latex/l3kernel/l3skip.sty +++ b/Master/texmf-dist/tex/latex/l3kernel/l3skip.sty @@ -47,7 +47,7 @@ %% %% ----------------------------------------------------------------------- \RequirePackage{l3bootstrap} -\GetIdInfo$Id: l3skip.dtx 4444 2013-01-13 20:27:20Z bruno $ +\GetIdInfo$Id: l3skip.dtx 4581 2013-07-28 08:38:50Z joseph $ {L3 Dimensions and skips} \ProvidesExplPackage {\ExplFileName}{\ExplFileDate}{\ExplFileVersion}{\ExplFileDescription} @@ -176,18 +176,33 @@ #1 \reverse_if:N #2 > #3 = { #1 #2 < #3 } \cs_new:Npn \__dim_compare_end:w #1 \prg_return_false: #2 \q_stop { #1 \prg_return_false: \else: \prg_return_true: \fi: } -\cs_new:Npn \dim_case:nnn #1 +\cs_new:Npn \dim_case:nnTF #1 { \tex_romannumeral:D - \exp_args:Nf \__dim_case_aux:nnn { \dim_eval:n {#1} } + \exp_args:Nf \__dim_case:nnTF { \dim_eval:n {#1} } } -\cs_new:Npn \__dim_case_aux:nnn #1#2#3 - { \__dim_case_aux:nw {#1} #2 {#1} {#3} \q_recursion_stop } -\cs_new:Npn \__dim_case_aux:nw #1#2#3 +\cs_new:Npn \dim_case:nnT #1#2#3 + { + \tex_romannumeral:D + \exp_args:Nf \__dim_case:nnTF { \dim_eval:n {#1} } {#2} {#3} { } + } +\cs_new:Npn \dim_case:nnF #1#2 + { + \tex_romannumeral:D + \exp_args:Nf \__dim_case:nnTF { \dim_eval:n {#1} } {#2} { } + } +\cs_new:Npn \dim_case:nn #1#2 + { + \tex_romannumeral:D + \exp_args:Nf \__dim_case:nnTF { \dim_eval:n {#1} } {#2} { } { } + } +\cs_new:Npn \__dim_case:nnTF #1#2#3#4 + { \__dim_case:nw {#1} #2 {#1} { } \q_mark {#3} \q_mark {#4} \q_stop } +\cs_new:Npn \__dim_case:nw #1#2#3 { \dim_compare:nNnTF {#1} = {#2} { \__dim_case_end:nw {#3} } - { \__dim_case_aux:nw {#1} } + { \__dim_case:nw {#1} } } \cs_new_eq:NN \__dim_case_end:nw \__prg_case_end:nw \cs_set:Npn \dim_while_do:nn #1#2 @@ -425,6 +440,7 @@ \muskip_new:N \l_tmpb_muskip \muskip_new:N \g_tmpa_muskip \muskip_new:N \g_tmpb_muskip +\cs_new_eq:NN \dim_case:nnn \dim_case:nnF %% %% %% End of file `l3skip.sty'. diff --git a/Master/texmf-dist/tex/latex/l3kernel/l3tl.sty b/Master/texmf-dist/tex/latex/l3kernel/l3tl.sty index 4cd85c60ac6..71c0e0c91e7 100644 --- a/Master/texmf-dist/tex/latex/l3kernel/l3tl.sty +++ b/Master/texmf-dist/tex/latex/l3kernel/l3tl.sty @@ -46,7 +46,7 @@ %% %% ----------------------------------------------------------------------- \RequirePackage{l3bootstrap} -\GetIdInfo$Id: l3tl.dtx 4482 2013-04-24 21:05:12Z joseph $ +\GetIdInfo$Id: l3tl.dtx 4581 2013-07-28 08:38:50Z joseph $ {L3 Token lists} \ProvidesExplPackage {\ExplFileName}{\ExplFileDate}{\ExplFileVersion}{\ExplFileDescription} @@ -369,18 +369,38 @@ \cs_new:Npn \tl_if_single:NTF { \exp_args:No \tl_if_single:nTF } \prg_new_conditional:Npnn \tl_if_single:n #1 { p , T , F , TF } { \__str_if_eq_x_return:nn { \exp_not:o { \use_none:nn #1 ?? } } {?} } -\cs_new:Npn \tl_case:Nnn #1#2#3 +\cs_new:Npn \tl_case:Nn #1#2 { \tex_romannumeral:D - \__tl_case:Nw #1 #2 #1 {#3} \q_recursion_stop + \__tl_case:NnTF #1 {#2} { } { } } +\cs_new:Npn \tl_case:NnT #1#2#3 + { + \tex_romannumeral:D + \__tl_case:NnTF #1 {#2} {#3} { } + } +\cs_new:Npn \tl_case:NnF #1#2#3 + { + \tex_romannumeral:D + \__tl_case:NnTF #1 {#2} { } {#3} + } +\cs_new:Npn \tl_case:NnTF #1#2 + { + \tex_romannumeral:D + \__tl_case:NnTF #1 {#2} + } +\cs_new:Npn \__tl_case:NnTF #1#2#3#4 + { \__tl_case:Nw #1 #2 #1 { } \q_mark {#3} \q_mark {#4} \q_stop } \cs_new:Npn \__tl_case:Nw #1#2#3 { \tl_if_eq:NNTF #1 #2 { \__tl_case_end:nw {#3} } { \__tl_case:Nw #1 } } -\cs_generate_variant:Nn \tl_case:Nnn { c } +\cs_generate_variant:Nn \tl_case:Nn { c } +\cs_generate_variant:Nn \tl_case:NnT { c } +\cs_generate_variant:Nn \tl_case:NnF { c } +\cs_generate_variant:Nn \tl_case:NnTF { c } \cs_new_eq:NN \__tl_case_end:nw \__prg_case_end:nw \cs_new:Npn \tl_map_function:nN #1#2 { @@ -751,6 +771,8 @@ \tl_new:N \g_tmpb_tl \tl_new:N \l_tmpa_tl \tl_new:N \l_tmpb_tl +\cs_new_eq:NN \tl_case:Nnn \tl_case:NnF +\cs_new_eq:NN \tl_case:cnn \tl_case:cnF %% %% %% End of file `l3tl.sty'. diff --git a/Master/texmf-dist/tex/latex/l3kernel/l3token.sty b/Master/texmf-dist/tex/latex/l3kernel/l3token.sty index 255da5c2d5e..65df10c3b6c 100644 --- a/Master/texmf-dist/tex/latex/l3kernel/l3token.sty +++ b/Master/texmf-dist/tex/latex/l3kernel/l3token.sty @@ -46,7 +46,7 @@ %% %% ----------------------------------------------------------------------- \RequirePackage{l3bootstrap} -\GetIdInfo$Id: l3token.dtx 4482 2013-04-24 21:05:12Z joseph $ +\GetIdInfo$Id: l3token.dtx 4581 2013-07-28 08:38:50Z joseph $ {L3 Experimental token manipulation} \ProvidesExplPackage {\ExplFileName}{\ExplFileDate}{\ExplFileVersion}{\ExplFileDescription} diff --git a/Master/texmf-dist/tex/latex/l3packages/l3keys2e/l3keys2e.sty b/Master/texmf-dist/tex/latex/l3packages/l3keys2e/l3keys2e.sty index dfa1f56700a..641251cfffb 100644 --- a/Master/texmf-dist/tex/latex/l3packages/l3keys2e/l3keys2e.sty +++ b/Master/texmf-dist/tex/latex/l3packages/l3keys2e/l3keys2e.sty @@ -46,8 +46,8 @@ %% %% ----------------------------------------------------------------------- %% -\RequirePackage{expl3}[2013/07/12] -\@ifpackagelater{expl3}{2013/07/12} +\RequirePackage{expl3}[2013/07/28] +\@ifpackagelater{expl3}{2013/07/28} {} {% \PackageError{l3keys2e}{Support package l3kernel too old} @@ -59,7 +59,7 @@ }% \endinput } -\GetIdInfo$Id: l3keys2e.dtx 4544 2013-07-12 07:14:52Z joseph $ +\GetIdInfo$Id: l3keys2e.dtx 4582 2013-07-28 08:57:13Z joseph $ {LaTeX2e option processing using LaTeX3 keys} \ProvidesExplPackage {\ExplFileName}{\ExplFileDate}{\ExplFileVersion}{\ExplFileDescription} diff --git a/Master/texmf-dist/tex/latex/l3packages/xparse/xparse.sty b/Master/texmf-dist/tex/latex/l3packages/xparse/xparse.sty index 705265bc4f3..274b5a005e6 100644 --- a/Master/texmf-dist/tex/latex/l3packages/xparse/xparse.sty +++ b/Master/texmf-dist/tex/latex/l3packages/xparse/xparse.sty @@ -50,8 +50,8 @@ %% %% ----------------------------------------------------------------------- %% -\RequirePackage{expl3}[2013/07/12] -\@ifpackagelater{expl3}{2013/07/12} +\RequirePackage{expl3}[2013/07/28] +\@ifpackagelater{expl3}{2013/07/28} {} {% \PackageError{xparse}{Support package l3kernel too old} @@ -63,7 +63,7 @@ }% \endinput } -\GetIdInfo$Id: xparse.dtx 4544 2013-07-12 07:14:52Z joseph $ +\GetIdInfo$Id: xparse.dtx 4582 2013-07-28 08:57:13Z joseph $ {L3 Experimental document command parser} \ProvidesExplPackage {\ExplFileName}{\ExplFileDate}{\ExplFileVersion}{\ExplFileDescription} diff --git a/Master/texmf-dist/tex/latex/l3packages/xtemplate/xtemplate.sty b/Master/texmf-dist/tex/latex/l3packages/xtemplate/xtemplate.sty index c561c724439..144817099c7 100644 --- a/Master/texmf-dist/tex/latex/l3packages/xtemplate/xtemplate.sty +++ b/Master/texmf-dist/tex/latex/l3packages/xtemplate/xtemplate.sty @@ -50,8 +50,8 @@ %% %% ----------------------------------------------------------------------- %% -\RequirePackage{expl3}[2013/07/12] -\@ifpackagelater{expl3}{2013/03/12} +\RequirePackage{expl3}[2013/07/28] +\@ifpackagelater{expl3}{2013/07/28} {} {% \PackageError{xtemplate}{Support package l3kernel too old} @@ -63,7 +63,7 @@ }% \endinput } -\GetIdInfo$Id: xtemplate.dtx 4544 2013-07-12 07:14:52Z joseph $ +\GetIdInfo$Id: xtemplate.dtx 4582 2013-07-28 08:57:13Z joseph $ {L3 Experimental prototype document functions} \ProvidesExplPackage {\ExplFileName}{\ExplFileDate}{\ExplFileVersion}{\ExplFileDescription} |