[latex3-commits] [git/LaTeX3-latex3-latex3] main: Drop most kernel_msg from l3trial (d3b47622b)
Joseph Wright
joseph.wright at morningstar2.co.uk
Thu Aug 26 14:44:07 CEST 2021
Repository : https://github.com/latex3/latex3
On branch : main
Link : https://github.com/latex3/latex3/commit/d3b47622bd122ab6f5b40baf0a661e30cc9102c3
>---------------------------------------------------------------
commit d3b47622bd122ab6f5b40baf0a661e30cc9102c3
Author: Joseph Wright <joseph.wright at morningstar2.co.uk>
Date: Thu Aug 26 13:44:07 2021 +0100
Drop most kernel_msg from l3trial
Those retained are:
- Explicitly defined in l3kernel-extras
- Linked to l3kernel (l3fp errors)
>---------------------------------------------------------------
d3b47622bd122ab6f5b40baf0a661e30cc9102c3
l3trial/l3fp-extras/l3fp-functions.dtx | 8 ++---
l3trial/l3fp-extras/l3fp-symbolic.dtx | 22 ++++++++------
l3trial/l3ldb/l3ldb.dtx | 8 ++---
l3trial/l3ldb/l3ldbparse.dtx | 4 +--
l3trial/l3str-format-new/l3str-format-new.dtx | 44 +++++++++++++--------------
l3trial/l3trace/l3trace.dtx | 10 +++---
l3trial/xfont/l3font.dtx | 6 ++--
7 files changed, 52 insertions(+), 50 deletions(-)
diff --git a/l3trial/l3fp-extras/l3fp-functions.dtx b/l3trial/l3fp-extras/l3fp-functions.dtx
index 0f45041a5..8f5f9d020 100644
--- a/l3trial/l3fp-extras/l3fp-functions.dtx
+++ b/l3trial/l3fp-extras/l3fp-functions.dtx
@@ -182,11 +182,11 @@
\cs_new_protected:Npn \@@_new_function:n #1
{
\@@_id_if_invalid:nTF {#1}
- { \__kernel_msg_error:nnn { fp } { invalid-identifier } {#1} }
+ { \msg_error:nnn { fp } { invalid-identifier } {#1} }
{
\cs_if_exist:cT { @@_parse_word_#1:N }
{
- \__kernel_msg_error:nnn
+ \msg_error:nnn
{ fp } { id-already-defined } {#1}
\cs_undefine:c { @@_parse_word_#1:N }
\cs_undefine:c { @@_#1_o:w }
@@ -218,7 +218,7 @@
{
\cs_if_exist:NTF #2
{
- \__kernel_msg_warning:nnnn
+ \msg_warning:nnnn
{ fp } { id-used-elsewhere } {#3} { function }
#1 #2 \@@_tmp:w
}
@@ -281,7 +281,7 @@
\cs_new_protected:Npn \@@_set_function:Nnnn #1#2#3#4
{
\@@_id_if_invalid:nTF {#2}
- { \__kernel_msg_error:nnn { fp } { invalid-identifier } {#2} }
+ { \msg_error:nnn { fp } { invalid-identifier } {#2} }
{
\cs_if_exist:cF { @@_parse_word_#2:N }
{ \@@_function_set_parsing:Nn \cs_set_eq:NN {#2} }
diff --git a/l3trial/l3fp-extras/l3fp-symbolic.dtx b/l3trial/l3fp-extras/l3fp-symbolic.dtx
index 9fd6efde3..65b4efcbe 100644
--- a/l3trial/l3fp-extras/l3fp-symbolic.dtx
+++ b/l3trial/l3fp-extras/l3fp-symbolic.dtx
@@ -567,7 +567,7 @@
{
\cs_if_exist:NTF #2
{
- \__kernel_msg_warning:nnnn
+ \msg_warning:nnnn
{ fp } { id-used-elsewhere } {#3} { variable }
#1 #2 \@@_tmp:w
}
@@ -586,7 +586,7 @@
\cs_new_protected:Npn \fp_clear_variable:n #1
{
\@@_id_if_invalid:nTF {#1}
- { \__kernel_msg_error:nnn { fp } { id-invalid } {#1} }
+ { \msg_error:nnn { fp } { id-invalid } {#1} }
{ \exp_args:No \@@_clear_variable:n { \tl_to_str:n {#1} } }
}
\cs_new_protected:Npn \@@_clear_variable:n #1
@@ -607,14 +607,14 @@
\cs_new_protected:Npn \fp_new_variable:n #1
{
\@@_id_if_invalid:nTF {#1}
- { \__kernel_msg_error:nnn { fp } { id-invalid } {#1} }
+ { \msg_error:nnn { fp } { id-invalid } {#1} }
{ \exp_args:No \@@_new_variable:n { \tl_to_str:n {#1} } }
}
\cs_new_protected:Npn \@@_new_variable:n #1
{
\cs_if_exist:cT { @@_parse_word_#1:N }
{
- \__kernel_msg_error:nnn
+ \msg_error:nnn
{ fp } { id-already-defined } {#1}
\cs_undefine:c { @@_parse_word_#1:N }
\cs_undefine:c { l_@@_variable_#1_fp }
@@ -645,7 +645,7 @@
\cs_new_protected:Npn \fp_set_variable:nn #1
{
\@@_id_if_invalid:nTF {#1}
- { \__kernel_msg_error:nnn { fp } { id-invalid } {#1} }
+ { \msg_error:nnn { fp } { id-invalid } {#1} }
{ \exp_args:No \@@_set_variable:nn { \tl_to_str:n {#1} } }
}
\cs_new_protected:Npn \@@_set_variable:nn #1#2
@@ -658,7 +658,7 @@
\fp_set:cn { l_@@_variable_#1_fp } { \l_@@_symbolic_fp }
\flag_if_raised:nT { @@_symbolic }
{
- \__kernel_msg_error:nnxxx { fp } { id-loop }
+ \msg_error:nnxxx { fp } { id-loop }
{ \tl_to_str:n {#1} }
{ \tl_to_str:n {#2} }
{ \fp_to_tl:N \l_@@_symbolic_fp }
@@ -689,27 +689,27 @@
% \subsection{Messages}
%
% \begin{macrocode}
-\__kernel_msg_new:nnnn { fp } { id-invalid }
+\msg_new:nnnn { fp } { id-invalid }
{ Floating~point~identifier~'#1'~invalid. }
{
\c__msg_coding_error_text_tl
LaTeX~has~been~asked~to~create~a~new~floating~point~identifier~'#1'~
but~this~may~only~contain~ASCII~letters.
}
-\__kernel_msg_new:nnnn { fp } { id-already-defined }
+\msg_new:nnnn { fp } { id-already-defined }
{ Floating~point~identifier~'#1'~already~defined. }
{
\c__msg_coding_error_text_tl
LaTeX~has~been~asked~to~create~a~new~floating~point~identifier~'#1'~
but~this~name~has~already~been~used~elsewhere.
}
-\__kernel_msg_new:nnnn { fp } { id-used-elsewhere }
+\msg_new:nnnn { fp } { id-used-elsewhere }
{ Floating~point~identifier~'#1'~already~used~for~something~else. }
{
LaTeX~has~been~asked~to~create~a~new~floating~point~identifier~'#1'~
but~this~name~is~used,~and~is~not~a~user-defined~#2.
}
-\__kernel_msg_new:nnnn { fp } { id-loop }
+\msg_new:nnnn { fp } { id-loop }
{ Variable~'#1'~used~in~the~definition~of~'#1'. }
{
\c__msg_coding_error_text_tl
@@ -717,6 +717,8 @@
to~the~expression~'#2'.~Evaluating~this~expression~yields~'#3',~
which~contains~'#1'~itself.
}
+\prop_gput:Nnn \g_msg_module_name_prop { fp } { LaTeX3 }
+\prop_gput:Nnn \g_msg_module_type_prop { fp } { }
% \end{macrocode}
%
% \subsection{Road-map}
diff --git a/l3trial/l3ldb/l3ldb.dtx b/l3trial/l3ldb/l3ldb.dtx
index 974debf99..ee51ff906 100644
--- a/l3trial/l3ldb/l3ldb.dtx
+++ b/l3trial/l3ldb/l3ldb.dtx
@@ -490,7 +490,7 @@
\fi:
\tl_set_eq:NN \l_ldb_internal_tl \l_ldb_tb_tl
\or: % end
- \__kernel_msg_expandable_error:nn { ldb } { impossible }
+ \msg_expandable_error:nn { ldb } { impossible }
\or: % complete
\if_meaning:w \l_ldb_tc_tl \q_nil
\cs_ggen_prop:N \l_ldb_tc_tl
@@ -814,7 +814,7 @@
{
\if_meaning:w \q_nil #2
\else:
- \__kernel_msg_expandable_error:nnfff { ldb } { not-nil }
+ \msg_expandable_error:nnfff { ldb } { not-nil }
{ \tl_to_str:n {#1} } { \token_to_str:N #2 } { \tl_to_str:N #2 }
\fi:
}
@@ -1234,8 +1234,8 @@
% \end{macro}
%
% \begin{macrocode}
-\__kernel_msg_new:nnn { ldb } { impossible } { Not~possible }
-\__kernel_msg_new:nnn { ldb } { not-nil } { Not~ nil~ #1:~ #2~containing:~#3 }
+\msg_new:nnn { ldb } { impossible } { Not~possible }
+\msg_new:nnn { ldb } { not-nil } { Not~ nil~ #1:~ #2~containing:~#3 }
% \end{macrocode}
%
% \begin{macrocode}
diff --git a/l3trial/l3ldb/l3ldbparse.dtx b/l3trial/l3ldb/l3ldbparse.dtx
index a2cec64e5..31744cc7b 100644
--- a/l3trial/l3ldb/l3ldbparse.dtx
+++ b/l3trial/l3ldb/l3ldbparse.dtx
@@ -275,8 +275,8 @@
% including the \cs{q_error} token.
% \begin{macrocode}
\cs_new_protected:Npn \ldb_error:w #1 \q_error
- { \__kernel_msg_error:nn { ldb } { illegal-context } }
-\__kernel_msg_new:nnnn { ldb } { illegal-context }
+ { \msg_error:nn { ldb } { illegal-context } }
+\msg_new:nnnn { ldb } { illegal-context }
{ Illegal~LDB~context:~\g_ldb_spec_tl.}
{
This~context~specification~is~illegal~and~
diff --git a/l3trial/l3str-format-new/l3str-format-new.dtx b/l3trial/l3str-format-new/l3str-format-new.dtx
index 101c48d86..34da6a8cd 100644
--- a/l3trial/l3str-format-new/l3str-format-new.dtx
+++ b/l3trial/l3str-format-new/l3str-format-new.dtx
@@ -351,7 +351,7 @@
\cs_new:Npn \@@_format_keyval_many:ww
= \q_mark #1 \q_mark #2 \q_mark \q_stop
{
- \__kernel_msg_expandable_error:nnn
+ \msg_expandable_error:nnn
{ keyval } { extra-equals } { #1 #2 }
}
% \end{macrocode}
@@ -359,7 +359,7 @@
% \end{macro}
%
% \begin{macrocode}
-\__kernel_msg_new:nnn { keyval } { extra-equals }
+\msg_new:nnn { keyval } { extra-equals }
{ Two~'='~in~'#1' }
% \end{macrocode}
%
@@ -519,7 +519,7 @@
\cs_if_exist_use:cTF { @@_format / #1 :nn }
{ {#1} {#2} }
{
- \__kernel_msg_expandable_error:nnnn
+ \msg_expandable_error:nnnn
{ str-format } { unknown-key } {#1} {#2}
}
}
@@ -545,7 +545,7 @@
}
}
{
- \__kernel_msg_expandable_error:nnnn
+ \msg_expandable_error:nnnn
{ str-format } { invalid-value } {#1} {#2}
}
}
@@ -564,7 +564,7 @@
{
\@@_format_val_do:fn { \str_head:n {#1} }
{
- \__kernel_msg_expandable_error:nnnn
+ \msg_expandable_error:nnnn
{ str-format } { invalid-value } {#1}
}
}
@@ -608,7 +608,7 @@
% { + } { \@@_format_key:nn { + } { + } }
% }
% {
- % \__kernel_msg_expandable_error:nnnn
+ % \msg_expandable_error:nnnn
% { str-format } { invalid-value } {#1} {#2}
% }
% }
@@ -616,11 +616,11 @@
% \end{macro}
%
% \begin{macrocode}
-\__kernel_msg_new:nnn { str-format } { unknown-key }
+\msg_new:nnn { str-format } { unknown-key }
{ Unknown~key~'#1'~for~string~format. }
-\__kernel_msg_new:nnn { str-format } { invalid-value }
+\msg_new:nnn { str-format } { invalid-value }
{ Key~'#1'~given~invalid~value~'#2'. }
-\__kernel_msg_new:nnn { str-format } { invalid-style }
+\msg_new:nnn { str-format } { invalid-style }
{ The~style~'#1'~is~invalid~for~type~'#2'. }
% \end{macrocode}
%
@@ -668,7 +668,7 @@
\cs_if_exist:cTF { @@_format_align_#1:nnnn }
{ \exp_args:Nc \exp_args:Nf { @@_format_align_#1:nnnn } }
{
- \__kernel_msg_expandable_error:nnnn
+ \msg_expandable_error:nnnn
{ str-format } { invalid-value } { alignment } {#1}
\exp_args:Nc \exp_args:Nf { @@_format_align_<:nnnn }
}
@@ -753,7 +753,7 @@
{
\cs_if_exist_use:cF { @@_format_fp_#2:nn }
{
- \__kernel_msg_expandable_error:nnnn
+ \msg_expandable_error:nnnn
{ str-format } { invalid-style } {#2} { fp }
\@@_format_fp_g:nn
}
@@ -1112,7 +1112,7 @@
\cs_new:Npn \@@_format_python_end:nwn #1 #2 \s_stop \s_stop #3
{
\tl_if_empty:nF {#2}
- { \__kernel_msg_expandable_error:nnn { str } { invalid-format } {#3} }
+ { \msg_expandable_error:nnn { str } { invalid-format } {#3} }
#1
}
% \end{macrocode}
@@ -1159,7 +1159,7 @@
{
\token_if_eq_charcode:NNTF #2 =
{
- \__kernel_msg_expandable_error:nnnn
+ \msg_expandable_error:nnnn
{ str } { invalid-align-format } {#2} {tl}
\@@_format_put:nw { #1 < }
}
@@ -1170,7 +1170,7 @@
}
\token_if_eq_charcode:NNF #3 ?
{
- \__kernel_msg_expandable_error:nnnn
+ \msg_expandable_error:nnnn
{ str } { invalid-sign-format } {#3} {tl}
}
\@@_format_put:nw { {#4} }
@@ -1181,7 +1181,7 @@
{
\token_if_eq_charcode:NNF #6 ?
{
- \__kernel_msg_expandable_error:nnnn
+ \msg_expandable_error:nnnn
{ str } { invalid-style-format } {#6} {tl}
}
}
@@ -1335,7 +1335,7 @@
\@@_format_put:nw { {#4} }
\tl_if_empty:nF {#5}
{
- \__kernel_msg_expandable_error:nnnn
+ \msg_expandable_error:nnnn
{ str } { invalid-precision-format } {#5} {int}
}
\str_case:nnF {#6}
@@ -1347,7 +1347,7 @@
{ X } { \@@_format_int:NwnnNNn \int_to_Hex:n }
}
{
- \__kernel_msg_expandable_error:nnnn
+ \msg_expandable_error:nnnn
{ str } { invalid-style-format } {#6} { int }
\@@_format_int:NwnnNNn \use:n
}
@@ -1388,15 +1388,15 @@
% All of the messages are produced expandably, so there is no need for
% an extra-text.
% \begin{macrocode}
-\__kernel_msg_new:nnn { str } { invalid-format }
+\msg_new:nnn { str } { invalid-format }
{ Invalid~format~'#1'. }
-\__kernel_msg_new:nnn { str } { invalid-align-format }
+\msg_new:nnn { str } { invalid-align-format }
{ Invalid~alignment~'#1'~for~style~'#2'. }
-\__kernel_msg_new:nnn { str } { invalid-sign-format }
+\msg_new:nnn { str } { invalid-sign-format }
{ Invalid~sign~'#1'~for~style~'#2'. }
-\__kernel_msg_new:nnn { str } { invalid-precision-format }
+\msg_new:nnn { str } { invalid-precision-format }
{ Invalid~precision~'#1'~for~style~'#2'. }
-\__kernel_msg_new:nnn { str } { invalid-style-format }
+\msg_new:nnn { str } { invalid-style-format }
{ Invalid~style~'#1'~for~type~'#2'. }
% \end{macrocode}
%
diff --git a/l3trial/l3trace/l3trace.dtx b/l3trial/l3trace/l3trace.dtx
index 7ab0034c5..10913704e 100644
--- a/l3trial/l3trace/l3trace.dtx
+++ b/l3trial/l3trace/l3trace.dtx
@@ -145,13 +145,13 @@
\int_if_exist:cTF { g_trace_ \tl_to_str:n {#1} _level_int }
{ \prg_return_true: }
{
- \__kernel_msg_error:nnx { trace } { module-not-declared }
+ \msg_error:nnx { trace } { module-not-declared }
{ \tl_to_str:n {#1} }
\prg_return_false:
}
}
\cs_generate_variant:Nn \trace_chk_module_declared:nT { V }
-\__kernel_msg_new:nnnn { trace } { module-not-declared }
+\msg_new:nnnn { trace } { module-not-declared }
{ The~module~#1~does~not~provide~tracing~information. }
{
Either~there~is~no~module~called~#1,~or~it~was~not~declared~
@@ -208,7 +208,7 @@
\tl_set:Nx \l_trace_internal_b_tl { \tl_to_str:n {#1} }
\tl_if_eq:NNF \l_trace_internal_a_tl \l_trace_internal_b_tl
{
- \__kernel_msg_error:nn { trace } { mismatched-pop }
+ \msg_error:nn { trace } { mismatched-pop }
{ \tl_to_str:N \l_trace_internal_a_tl }
{ \tl_to_str:N \l_trace_internal_b_tl }
}
@@ -218,7 +218,7 @@
}
\cs_new_protected:Npn \trace_pop:nnn #1#2#3
{ \trace_pop:nnx {#1} {#2} { \exp_not:n {#3} } }
- % \__kernel_msg_new:nnn { trace } { mismatched-pop } { }
+ % \msg_new:nnn { trace } { mismatched-pop } { }
% \end{macrocode}
% \end{macro}
%
@@ -405,7 +405,7 @@
}
{ } { } { }
}
-\__kernel_msg_new:nnn { trace } { show-marks }
+\msg_new:nnn { trace } { show-marks }
{ The~marks~on~this~page~are #1 }
% \end{macrocode}
% \end{macro}
diff --git a/l3trial/xfont/l3font.dtx b/l3trial/xfont/l3font.dtx
index cf4251f82..31dd1c663 100644
--- a/l3trial/xfont/l3font.dtx
+++ b/l3trial/xfont/l3font.dtx
@@ -446,17 +446,17 @@
{
\cs_new_protected:Npn \font_suppress_not_found_error:
{
- \__kernel_msg_warning:nnx {l3font} {cmd-pdftex-unavail}
+ \msg_warning:nnx {l3font} {cmd-pdftex-unavail}
{ \font_suppress_not_found_error: }
}
\cs_new_protected:Npn \font_enable_not_found_error:
{
- \__kernel_msg_warning:nnx {l3font} {cmd-pdftex-unavail}
+ \msg_warning:nnx {l3font} {cmd-pdftex-unavail}
{ \font_enable_not_found_error: }
}
}
}
-\__kernel_msg_new:nnn {l3font} {cmd-pdftex-unavail}
+\msg_new:nnn {l3font} {cmd-pdftex-unavail}
{ The~command~`#1'~is~not~available~for~the~pdfTeX~engine. }
% \end{macrocode}
% \end{macro}
More information about the latex3-commits
mailing list.