Skip to content

Commit

Permalink
Switch from x- to e-type in l3msg
Browse files Browse the repository at this point in the history
  • Loading branch information
josephwright committed Sep 26, 2023
1 parent c2d7070 commit 69f656b
Show file tree
Hide file tree
Showing 44 changed files with 453 additions and 340 deletions.
8 changes: 4 additions & 4 deletions l3experimental/l3bitset/l3bitset.dtx
Original file line number Diff line number Diff line change
Expand Up @@ -434,7 +434,7 @@
\prop_gput:cnn { g_@@_ \cs_to_str:N #2 _name_prop } {#3} {#3}
}
{
\msg_warning:nnxx { bitset } { unknown-name }
\msg_warning:nnee { bitset } { unknown-name }
{ \token_to_str:N #2 }
{ \tl_to_str:n {#3} }
}
Expand Down Expand Up @@ -531,11 +531,11 @@
% \bitset_log:N, \bitset_log:c
% }
% \begin{macrocode}
\cs_new_protected:Npn \bitset_show:N { \@@_show:NN \msg_show:nnxxxx }
\cs_new_protected:Npn \bitset_show:N { \@@_show:NN \msg_show:nneeee }
\cs_generate_variant:Nn \bitset_show:N { c }
\cs_new_protected:Npn \bitset_log:N { \@@_show:NN \msg_log:nnxxxx }
\cs_new_protected:Npn \bitset_log:N { \@@_show:NN \msg_log:nneeee }
\cs_generate_variant:Nn \bitset_log:N { c }
\cs_new_protected:Npn \bitset_show_named_index:N { \@@_show_named_index:NN \msg_show:nnxxxx }
\cs_new_protected:Npn \bitset_show_named_index:N { \@@_show_named_index:NN \msg_show:nneeee }
\cs_generate_variant:Nn \bitset_show_named_index:N { c }
\cs_new_protected:Npn \@@_show:NN #1#2
{
Expand Down
4 changes: 2 additions & 2 deletions l3experimental/l3graphics/l3graphics.dtx
Original file line number Diff line number Diff line change
Expand Up @@ -615,8 +615,8 @@
% \begin{macro}[EXP]{\@@_list_aux:n}
% A function to list all graphic files used.
% \begin{macrocode}
\cs_new_protected:Npn \graphics_show_list: { \@@_list:N \msg_show:nnxxxx }
\cs_new_protected:Npn \graphics_log_list: { \@@_list:N \msg_log:nnxxxx }
\cs_new_protected:Npn \graphics_show_list: { \@@_list:N \msg_show:nneeee }
\cs_new_protected:Npn \graphics_log_list: { \@@_list:N \msg_log:nneeee }
\cs_new_protected:Npn \@@_list:N #1
{
\seq_remove_duplicates:N \g_@@_record_seq
Expand Down
34 changes: 17 additions & 17 deletions l3kernel/l3basics.dtx
Original file line number Diff line number Diff line change
Expand Up @@ -1986,7 +1986,7 @@
{ \@@_generate_conditional:nnNNNnnn {#1} {#2} #3 #4 #5 }
{ \tl_count:n {#2} }
{
\msg_error:nnxx { kernel } { bad-number-of-arguments }
\msg_error:nnee { kernel } { bad-number-of-arguments }
{ \token_to_str:c { #1 : #2 } }
{ \tl_count:n {#2} }
\use_none:nn
Expand Down Expand Up @@ -2024,7 +2024,7 @@
\cs_set_protected:Npn \@@_generate_conditional:nnNNNnnn #1#2#3#4#5#6#7#8
{
\if_meaning:w \c_false_bool #3
\msg_error:nnx { kernel } { missing-colon }
\msg_error:nne { kernel } { missing-colon }
{ \token_to_str:c {#1} }
\exp_after:wN \use_none:nn
\fi:
Expand Down Expand Up @@ -2064,7 +2064,7 @@
\use:c { @@_generate_ #8 _form:wNNnnnnN }
\tl_if_empty:nF {#8}
{
\msg_error:nnxx
\msg_error:nnee
{ kernel } { conditional-form-unknown }
{#8} { \token_to_str:c { #3 : #4 } }
}
Expand Down Expand Up @@ -2118,7 +2118,7 @@
{ #7 \@@_p_true:w \fi: \c_false_bool }
}
{
\msg_error:nnx { kernel } { protected-predicate }
\msg_error:nne { kernel } { protected-predicate }
{ \token_to_str:c { #4 _p: #5 } }
}
}
Expand Down Expand Up @@ -2216,12 +2216,12 @@
\cs_set_protected:Npn \@@_set_eq_conditional:nnNnnNNw #1#2#3#4#5#6
{
\if_meaning:w \c_false_bool #3
\msg_error:nnx { kernel } { missing-colon }
\msg_error:nne { kernel } { missing-colon }
{ \token_to_str:c {#1} }
\exp_after:wN \@@_use_none_delimit_by_q_recursion_stop:w
\fi:
\if_meaning:w \c_false_bool #6
\msg_error:nnx { kernel } { missing-colon }
\msg_error:nne { kernel } { missing-colon }
{ \token_to_str:c {#4} }
\exp_after:wN \@@_use_none_delimit_by_q_recursion_stop:w
\fi:
Expand All @@ -2235,7 +2235,7 @@
\use:c { @@_set_eq_conditional_ #6 _form:wNnnnn }
\tl_if_empty:nF {#6}
{
\msg_error:nnxx
\msg_error:nnee
{ kernel } { conditional-form-unknown }
{#6} { \token_to_str:c { #1 : #2 } }
}
Expand Down Expand Up @@ -2554,14 +2554,14 @@
% only temporary, they will be redefined later on.
%
% \begin{macro}
% {\msg_error:nnxx, \msg_error:nnx, \msg_error:nn}
% {\msg_error:nnee, \msg_error:nne, \msg_error:nn}
% If an internal error occurs before \LaTeX3 has loaded \pkg{l3msg} then
% the code should issue a usable if terse error message and halt. This
% can only happen if a coding error is made by the team, so this is
% a reasonable response. Setting the \tn{newlinechar} is needed, to
% turn |^^J| into a proper line break in plain \TeX{}.
% \begin{macrocode}
\cs_set_protected:Npn \msg_error:nnxx #1#2#3#4
\cs_set_protected:Npn \msg_error:nnee #1#2#3#4
{
\tex_newlinechar:D = `\^^J \scan_stop:
\tex_errmessage:D
Expand All @@ -2574,10 +2574,10 @@
}
\tex_end:D
}
\cs_set_protected:Npn \msg_error:nnx #1#2#3
{ \msg_error:nnxx {#1} {#2} {#3} { } }
\cs_set_protected:Npn \msg_error:nne #1#2#3
{ \msg_error:nnee {#1} {#2} {#3} { } }
\cs_set_protected:Npn \msg_error:nn #1#2
{ \msg_error:nnxx {#1} {#2} { } { } }
{ \msg_error:nnee {#1} {#2} { } { } }
% \end{macrocode}
% \end{macro}
%
Expand Down Expand Up @@ -2614,7 +2614,7 @@
{
\cs_if_free:NF #1
{
\msg_error:nnxx { kernel } { command-already-defined }
\msg_error:nnee { kernel } { command-already-defined }
{ \token_to_str:N #1 } { \token_to_meaning:N #1 }
}
}
Expand Down Expand Up @@ -2914,7 +2914,7 @@
{
\__kernel_cs_parm_from_arg_count:nnF { \use:nnn #2 #1 } {#3}
{
\msg_error:nnxx { kernel } { bad-number-of-arguments }
\msg_error:nnee { kernel } { bad-number-of-arguments }
{ \token_to_str:N #1 } { \int_eval:n {#3} }
\use_none:n
}
Expand Down Expand Up @@ -2995,14 +2995,14 @@
{ \tl_map_function:nN {#2} \@@_generate_from_signature:n }
\tl_if_empty:oF \@@_tmp:w
{
\msg_error:nnxxx { kernel } { non-base-function }
\msg_error:nneee { kernel } { non-base-function }
{ \token_to_str:N #5 } {#2} { \@@_tmp:w }
}
\cs_generate_from_arg_count:NNnn
#5 #4 { \tl_count:n {#2} } {#6}
}
{
\msg_error:nnx { kernel } { missing-colon }
\msg_error:nne { kernel } { missing-colon }
{ \token_to_str:N #5 }
}
}
Expand Down Expand Up @@ -3133,7 +3133,7 @@
\cs_if_exist:NTF #1
{#2}
{
\msg_error:nnx { kernel } { variable-not-defined }
\msg_error:nne { kernel } { variable-not-defined }
{ \token_to_str:N #1 }
}
}
Expand Down
2 changes: 1 addition & 1 deletion l3kernel/l3box.dtx
Original file line number Diff line number Diff line change
Expand Up @@ -1372,7 +1372,7 @@
\group_end:
}
{
\msg_error:nnx { kernel } { variable-not-defined }
\msg_error:nne { kernel } { variable-not-defined }
{ \token_to_str:N #2 }
}
}
Expand Down
6 changes: 3 additions & 3 deletions l3kernel/l3cctab.dtx
Original file line number Diff line number Diff line change
Expand Up @@ -652,7 +652,7 @@
}
{ \cs_if_exist_p:c { @@_group_ #1 _chk: } }
{
\msg_error:nnx { cctab } { group-mismatch }
\msg_error:nne { cctab } { group-mismatch }
{
\int_sign:n
{ \tex_currentgrouplevel:D - \l_@@_internal_b_tl }
Expand Down Expand Up @@ -756,13 +756,13 @@
\@@_chk_if_valid_aux:NTF #1
{ \prg_return_true: }
{
\msg_error:nnx { cctab } { invalid-cctab }
\msg_error:nne { cctab } { invalid-cctab }
{ \token_to_str:N #1 }
\prg_return_false:
}
}
{
\msg_error:nnx { kernel } { command-not-defined }
\msg_error:nne { kernel } { command-not-defined }
{ \token_to_str:N #1 }
\prg_return_false:
}
Expand Down
10 changes: 5 additions & 5 deletions l3kernel/l3clist.dtx
Original file line number Diff line number Diff line change
Expand Up @@ -2182,9 +2182,9 @@
% |#2| serving as a dummy code to prevent a check performed by this
% auxiliary.
% \begin{macrocode}
\cs_new_protected:Npn \clist_show:N { \@@_show:NN \msg_show:nnxxxx }
\cs_new_protected:Npn \clist_show:N { \@@_show:NN \msg_show:nneeee }
\cs_generate_variant:Nn \clist_show:N { c }
\cs_new_protected:Npn \clist_log:N { \@@_show:NN \msg_log:nnxxxx }
\cs_new_protected:Npn \clist_log:N { \@@_show:NN \msg_log:nneeee }
\cs_generate_variant:Nn \clist_log:N { c }
\cs_new_protected:Npn \@@_show:NN #1#2
{
Expand All @@ -2199,7 +2199,7 @@
{ } { }
}
{
\msg_error:nnxx { clist } { non-clist }
\msg_error:nnee { clist } { non-clist }
{ \token_to_str:N #2 } { \tl_to_str:N #2 }
}
}
Expand All @@ -2211,8 +2211,8 @@
% A variant of the above: no existence check, empty first argument for
% the message.
% \begin{macrocode}
\cs_new_protected:Npn \clist_show:n { \@@_show:Nn \msg_show:nnxxxx }
\cs_new_protected:Npn \clist_log:n { \@@_show:Nn \msg_log:nnxxxx }
\cs_new_protected:Npn \clist_show:n { \@@_show:Nn \msg_show:nneeee }
\cs_new_protected:Npn \clist_log:n { \@@_show:Nn \msg_log:nneeee }
\cs_new_protected:Npn \@@_show:Nn #1#2
{
#1 { clist } { show }
Expand Down
16 changes: 8 additions & 8 deletions l3kernel/l3coffins.dtx
Original file line number Diff line number Diff line change
Expand Up @@ -602,7 +602,7 @@
\coffin_if_exist:NTF #1
{ #2 }
{
\msg_error:nnx { coffin } { unknown }
\msg_error:nne { coffin } { unknown }
{ \token_to_str:N #1 }
}
}
Expand Down Expand Up @@ -949,7 +949,7 @@
\prop_get:cnNF
{ coffin ~ \@@_to_value:N #1 ~ poles } {#2} #3
{
\msg_error:nnxx { coffin } { unknown-pole }
\msg_error:nnee { coffin } { unknown-pole }
{ \exp_not:n {#2} } { \token_to_str:N #1 }
\tl_set:Nn #3 { { 0pt } { 0pt } { 0pt } { 0pt } }
}
Expand Down Expand Up @@ -2490,10 +2490,10 @@
% structure then the code complains.
% \begin{macrocode}
\cs_new_protected:Npn \coffin_show_structure:N
{ \@@_show_structure:NN \msg_show:nnxxxx }
{ \@@_show_structure:NN \msg_show:nneeee }
\cs_generate_variant:Nn \coffin_show_structure:N { c }
\cs_new_protected:Npn \coffin_log_structure:N
{ \@@_show_structure:NN \msg_log:nnxxxx }
{ \@@_show_structure:NN \msg_log:nneeee }
\cs_generate_variant:Nn \coffin_log_structure:N { c }
\cs_new_protected:Npn \@@_show_structure:NN #1#2
{
Expand Down Expand Up @@ -2525,8 +2525,8 @@
% }
% Essentially a combination of \cs{coffin_show_structure:N} and
% \cs{box_show:Nnn}, but we need to avoid having two prompts, so we
% use \cs{msg_term:nnxxxx} instead of
% \cs{msg_show:nnxxxx} in the |show| case.
% use \cs{msg_term:nneeee} instead of
% \cs{msg_show:nneeee} in the |show| case.
% \begin{macrocode}
\cs_new_protected:Npn \coffin_show:N #1
{ \coffin_show:Nnn #1 \c_max_int \c_max_int }
Expand All @@ -2535,10 +2535,10 @@
{ \coffin_log:Nnn #1 \c_max_int \c_max_int }
\cs_generate_variant:Nn \coffin_log:N { c }
\cs_new_protected:Npn \coffin_show:Nnn
{ \@@_show:NNNnn \msg_term:nnxxxx \box_show:Nnn }
{ \@@_show:NNNnn \msg_term:nneeee \box_show:Nnn }
\cs_generate_variant:Nn \coffin_show:Nnn { c }
\cs_new_protected:Npn \coffin_log:Nnn
{ \@@_show:NNNnn \msg_log:nnxxxx \box_show:Nnn }
{ \@@_show:NNNnn \msg_log:nneeee \box_show:Nnn }
\cs_generate_variant:Nn \coffin_log:Nnn { c }
\cs_new_protected:Npn \@@_show:NNNnn #1#2#3#4#5
{
Expand Down
4 changes: 2 additions & 2 deletions l3kernel/l3color.dtx
Original file line number Diff line number Diff line change
Expand Up @@ -3047,9 +3047,9 @@
% is similar to the keys module here.
% \begin{macrocode}
\cs_new_protected:Npn \color_show:n
{ \@@_show:Nn \msg_show:nnxxxx }
{ \@@_show:Nn \msg_show:nneeee }
\cs_new_protected:Npn \color_log:n
{ \@@_show:Nn \msg_log:nnxxxx }
{ \@@_show:Nn \msg_log:nneeee }
\cs_new_protected:Npn \@@_show:Nn #1#2
{
#1 { color } { show }
Expand Down
6 changes: 3 additions & 3 deletions l3kernel/l3debug.dtx
Original file line number Diff line number Diff line change
Expand Up @@ -269,7 +269,7 @@
\@@_suspended:T \use_none:nnn
\cs_if_exist:NF ##1
{
\msg_error:nnx { debug } { non-declared-variable }
\msg_error:nne { debug } { non-declared-variable }
{ \token_to_str:N ##1 }
}
}
Expand All @@ -278,7 +278,7 @@
\@@_suspended:T \use_none:nnn
\cs_if_exist:NF ##1
{
\msg_error:nnx { kernel } { command-not-defined }
\msg_error:nne { kernel } { command-not-defined }
{ \token_to_str:N ##1 }
}
}
Expand Down Expand Up @@ -362,7 +362,7 @@
\if:w #1 \scan_stop:
\cs_gset_nopar:Npn #1 {#2}
\else:
\msg_error:nnxxx { debug } { local-global }
\msg_error:nneee { debug } { local-global }
{#1} {#2} { \iow_char:N \\ #3 }
\fi:
\fi:
Expand Down
4 changes: 2 additions & 2 deletions l3kernel/l3deprecation.dtx
Original file line number Diff line number Diff line change
Expand Up @@ -149,7 +149,7 @@
{
\__kernel_if_debug:TF
{
\exp_not:N \msg_warning:nnxxx
\exp_not:N \msg_warning:nneee
{ deprecation } { deprecated-command }
{#1}
{ \token_to_str:N #3 }
Expand Down Expand Up @@ -193,7 +193,7 @@
\exp_not:N \msg_expandable_error:nnnnn
{ deprecation } { deprecated-command }
{ \tl_to_str:n {#3} } { \token_to_str:N #1 } { \tl_to_str:n {#2} }
\exp_not:N \msg_error:nnxxx
\exp_not:N \msg_error:nneee
{ deprecation } { deprecated-command }
{ \tl_to_str:n {#3} } { \token_to_str:N #1 } { \tl_to_str:n {#2} }
}
Expand Down
6 changes: 3 additions & 3 deletions l3kernel/l3doc.dtx
Original file line number Diff line number Diff line change
Expand Up @@ -1124,7 +1124,7 @@ and all files in that bundle must be distributed together.
\@@_trim_right:Nn \l_@@_detect_internals_tl _
\@@_trim_right:Nn \l_@@_detect_internals_tl :
\@@_trim_right:No \l_@@_detect_internals_tl { \token_to_str:N : }
\msg_warning:nnxxx { l3doc } { foreign-internal }
\msg_warning:nneee { l3doc } { foreign-internal }
{ \tl_to_str:N \l_@@_detect_internals_cs_tl }
{ \tl_to_str:N \l_@@_detect_internals_tl }
{ \tl_to_str:N \g_@@_module_name_tl }
Expand Down Expand Up @@ -2239,7 +2239,7 @@ and all files in that bundle must be distributed together.
}
{
\bool_if:NT \l_@@_macro_TF_bool
{ \msg_error:nnx { l3doc } { no-signature-TF } {#4} }
{ \msg_error:nne { l3doc } { no-signature-TF } {#4} }
\@@_names_parse_aux:nnn {#4} {#4} { \scan_stop: }
}
}
Expand Down Expand Up @@ -2473,7 +2473,7 @@ and all files in that bundle must be distributed together.
\exp_args:No \@@_date_compare:nNnT
{#1} > { \c_sys_year_int - \c_sys_month_int - \c_sys_day_int }
{
\msg_error:nnxx { l3doc } { future-date }
\msg_error:nnee { l3doc } { future-date }
{ \tl_to_str:N \l_@@_macro_argument_tl }
{#1}
}
Expand Down

0 comments on commit 69f656b

Please sign in to comment.