summaryrefslogtreecommitdiff
path: root/Master/texmf-dist/tex/latex/l3kernel/l3prg.sty
diff options
context:
space:
mode:
Diffstat (limited to 'Master/texmf-dist/tex/latex/l3kernel/l3prg.sty')
-rw-r--r--Master/texmf-dist/tex/latex/l3kernel/l3prg.sty42
1 files changed, 22 insertions, 20 deletions
diff --git a/Master/texmf-dist/tex/latex/l3kernel/l3prg.sty b/Master/texmf-dist/tex/latex/l3kernel/l3prg.sty
index e86d4214429..69475b6617b 100644
--- a/Master/texmf-dist/tex/latex/l3kernel/l3prg.sty
+++ b/Master/texmf-dist/tex/latex/l3kernel/l3prg.sty
@@ -46,7 +46,7 @@
%%
%% -----------------------------------------------------------------------
\RequirePackage{l3names}
-\GetIdInfo$Id: l3prg.dtx 3014 2011-11-27 06:55:43Z bruno $
+\GetIdInfo$Id: l3prg.dtx 3086 2011-12-22 17:55:46Z bruno $
{L3 Experimental control structures}
%%
\ProvidesExplPackage
@@ -54,15 +54,15 @@
\package_check_loaded_expl:
\tex_let:D \if_bool:N \tex_ifodd:D
\tex_let:D \if_predicate:w \tex_ifodd:D
-\cs_new_protected_nopar:Npn \bool_new:N #1 { \cs_new_eq:NN #1 \c_false_bool }
+\cs_new_protected:Npn \bool_new:N #1 { \cs_new_eq:NN #1 \c_false_bool }
\cs_generate_variant:Nn \bool_new:N { c }
-\cs_new_protected_nopar:Npn \bool_set_true:N #1
+\cs_new_protected:Npn \bool_set_true:N #1
{ \cs_set_eq:NN #1 \c_true_bool }
-\cs_new_protected_nopar:Npn \bool_set_false:N #1
+\cs_new_protected:Npn \bool_set_false:N #1
{ \cs_set_eq:NN #1 \c_false_bool }
-\cs_new_protected_nopar:Npn \bool_gset_true:N #1
+\cs_new_protected:Npn \bool_gset_true:N #1
{ \cs_gset_eq:NN #1 \c_true_bool }
-\cs_new_protected_nopar:Npn \bool_gset_false:N #1
+\cs_new_protected:Npn \bool_gset_false:N #1
{ \cs_gset_eq:NN #1 \c_false_bool }
\cs_generate_variant:Nn \bool_set_true:N { c }
\cs_generate_variant:Nn \bool_set_false:N { c }
@@ -193,8 +193,8 @@
\exp_after:wN \bool_not_choose:NN \exp_after:wN #1
\int_to_roman:w - `\q
}
-\cs_new_nopar:Npn \bool_choose:NN #1#2 { \use:c { bool_ #2 _ #1 :w } }
-\cs_new_nopar:Npn \bool_not_choose:NN #1#2 { \use:c { bool_not_ #2 _ #1 :w } }
+\cs_new:Npn \bool_choose:NN #1#2 { \use:c { bool_ #2 _ #1 :w } }
+\cs_new:Npn \bool_not_choose:NN #1#2 { \use:c { bool_not_ #2 _ #1 :w } }
\cs_new_nopar:cpn { bool_&_1:w } & { \bool_get_next:N }
\cs_new_nopar:cpn { bool_|_0:w } | { \bool_get_next:N }
\cs_new_nopar:cpn { bool_not_&_0:w } & { \bool_get_next:N }
@@ -335,18 +335,18 @@
{ \prg_case_tl_aux:Nw #1 }
}
\cs_generate_variant:Nn \prg_case_tl:Nnn { c }
-\cs_new_nopar:Npn \prg_replicate:nn #1
+\cs_new:Npn \prg_replicate:nn #1
{
\int_to_roman:w
\exp_after:wN \prg_replicate_first_aux:N
\int_value:w \int_eval:w #1 \int_eval_end:
\cs_end:
}
-\cs_new_nopar:Npn \prg_replicate_aux:N #1
+\cs_new:Npn \prg_replicate_aux:N #1
{ \cs:w prg_replicate_#1 :n \prg_replicate_aux:N }
-\cs_new_nopar:Npn \prg_replicate_first_aux:N #1
+\cs_new:Npn \prg_replicate_first_aux:N #1
{ \cs:w prg_replicate_first_ #1 :n \prg_replicate_aux:N }
-\cs_new_nopar:Npn \prg_replicate_ :n #1 { \cs_end: }
+\cs_new:Npn \prg_replicate_ :n #1 { \cs_end: }
\cs_new:cpn { prg_replicate_0:n } #1 { \cs_end: {#1#1#1#1#1#1#1#1#1#1} }
\cs_new:cpn { prg_replicate_1:n } #1 { \cs_end: {#1#1#1#1#1#1#1#1#1#1} #1 }
\cs_new:cpn { prg_replicate_2:n } #1 { \cs_end: {#1#1#1#1#1#1#1#1#1#1} #1#1 }
@@ -364,7 +364,8 @@
{ \cs_end: {#1#1#1#1#1#1#1#1#1#1} #1#1#1#1#1#1#1#1 }
\cs_new:cpn { prg_replicate_9:n } #1
{ \cs_end: {#1#1#1#1#1#1#1#1#1#1} #1#1#1#1#1#1#1#1#1 }
-\cs_new:cpn { prg_replicate_first_-:n } #1 { \c_zero \negative_replication }
+\cs_new:cpn { prg_replicate_first_-:n } #1
+ { \c_zero \msg_expandable_kernel_error:nn { prg } { replicate-neg } }
\cs_new:cpn { prg_replicate_first_0:n } #1 { \c_zero }
\cs_new:cpn { prg_replicate_first_1:n } #1 { \c_zero #1 }
\cs_new:cpn { prg_replicate_first_2:n } #1 { \c_zero #1#1 }
@@ -446,12 +447,13 @@
\tl_to_lowercase:n
{
\group_end:
- \cs_new_nopar:Npn \prg_variable_get_scope:N #1
+ \cs_new:Npn \prg_variable_get_scope:N #1
{
- \exp_last_unbraced:Nf \prg_variable_get_scope_aux:w
- { \cs_to_str:N #1 \exp_stop_f: \q_stop }
+ \exp_after:wN \exp_after:wN
+ \exp_after:wN \prg_variable_get_scope_aux:w
+ \cs_to_str:N #1 \exp_stop_f: \q_stop
}
- \cs_new_nopar:Npn \prg_variable_get_scope_aux:w #1#2 \q_stop
+ \cs_new:Npn \prg_variable_get_scope_aux:w #1#2 \q_stop
{ \token_if_eq_meaning:NNT & #1 { g } }
}
\group_begin:
@@ -460,12 +462,12 @@
\tl_to_lowercase:n
{
\group_end:
- \cs_new_nopar:Npn \prg_variable_get_type:N #1
+ \cs_new:Npn \prg_variable_get_type:N #1
{
\exp_after:wN \prg_variable_get_type_aux:w
\token_to_str:N #1 & a \q_stop
}
- \cs_new_nopar:Npn \prg_variable_get_type_aux:w #1 & #2#3 \q_stop
+ \cs_new:Npn \prg_variable_get_type_aux:w #1 & #2#3 \q_stop
{
\token_if_eq_meaning:NNTF a #2
{#1}
@@ -473,7 +475,7 @@
}
}
\int_new:N \g_prg_map_int
-\cs_new_protected_nopar:Npn \prg_define_quicksort:nnn #1#2#3 {
+\cs_new_protected:Npn \prg_define_quicksort:nnn #1#2#3 {
\cs_set:cpx{#1_quicksort:n}##1{
\exp_not:c{#1_quicksort_start_partition:w} ##1
\exp_not:n{#2\q_nil#3\q_stop}