diff options
author | Karl Berry <karl@freefriends.org> | 2009-11-22 00:01:52 +0000 |
---|---|---|
committer | Karl Berry <karl@freefriends.org> | 2009-11-22 00:01:52 +0000 |
commit | c8f25e8c064910cbdae63d68ad0b753dcd925264 (patch) | |
tree | 50cd44cf48c386388aadae1d16b1adae5f917034 /Master/texmf-dist/tex/latex/expl3/l3msg.sty | |
parent | 3a4d88244a662af906112c56eb1982f9dacef5b2 (diff) |
expl3 1733 (21nov09)
git-svn-id: svn://tug.org/texlive/trunk@16114 c570f23f-e606-0410-a88d-b1316a301751
Diffstat (limited to 'Master/texmf-dist/tex/latex/expl3/l3msg.sty')
-rw-r--r-- | Master/texmf-dist/tex/latex/expl3/l3msg.sty | 329 |
1 files changed, 147 insertions, 182 deletions
diff --git a/Master/texmf-dist/tex/latex/expl3/l3msg.sty b/Master/texmf-dist/tex/latex/expl3/l3msg.sty index 757394ff669..04d32519912 100644 --- a/Master/texmf-dist/tex/latex/expl3/l3msg.sty +++ b/Master/texmf-dist/tex/latex/expl3/l3msg.sty @@ -49,7 +49,7 @@ %% ----------------------------------------------------------------------- %% \RequirePackage{l3names} -\GetIdInfo$Id: l3msg.dtx 1502 2009-09-01 16:23:32Z joseph $ +\GetIdInfo$Id: l3msg.dtx 1722 2009-11-06 13:22:12Z joseph $ {L3 Experimental LaTeX Messages module} \ProvidesExplPackage {\filename}{\filedate}{\fileversion}{\filedescription} @@ -95,88 +95,59 @@ \tl_new:Nn \c_msg_on_line_tl { on~line } \tl_new:Nn \c_msg_text_prefix_tl { msg_text ~>~ } \tl_new:Nn \c_msg_more_text_prefix_tl { msg_text_more ~>~ } -\tl_new:Nn \c_msg_code_prefix_tl { msg_code ~>~ } \tl_new:N \l_msg_class_tl \tl_new:N \l_msg_current_class_tl \clist_new:N \l_msg_names_clist \prop_new:N \l_msg_redirect_classes_prop \prop_new:N \l_msg_redirect_names_prop \clist_new:N \l_msg_redirect_classes_clist -\cs_new_nopar:Nn { \msg_line_number: } { +\cs_new_nopar:Npn \msg_line_number: { \toks_use:N \tex_inputlineno:D } -\cs_new_nopar:Nn { \msg_line_context: } { - \msg_space: +\cs_new_nopar:Npn \msg_line_context: { \c_msg_on_line_tl \msg_space: \msg_line_number: } -\cs_new_nopar:Nn \msg_newline: { ^^J } -\cs_new_nopar:Nn \msg_two_newlines: { ^^J ^^J } -\cs_new_nopar:Nn \msg_space: { ~ } -\cs_new_nopar:Nn \msg_two_spaces: { \msg_space: \msg_space: } -\cs_new_nopar:Nn \msg_four_spaces: { \msg_two_spaces: \msg_two_spaces: } -\cs_new_nopar:Npn \msg_generic_new:nnnn #1 { - \exp_args:Nc \chk_if_free_cs:N { \c_msg_text_prefix_tl #1 :nn } - \msg_generic_set:nnnn {#1} +\cs_new_nopar:Npn \msg_newline: { ^^J } +\cs_new_nopar:Npn \msg_two_newlines: { ^^J ^^J } +\cs_new_nopar:Npn \msg_space: { ~ } +\cs_new_nopar:Npn \msg_two_spaces: { \msg_space: \msg_space: } +\cs_new_nopar:Npn \msg_four_spaces: { + \msg_two_spaces: \msg_two_spaces: } \cs_new_nopar:Npn \msg_generic_new:nnn #1 { - \exp_args:Nc \chk_if_free_cs:N { \c_msg_text_prefix_tl #1 :nn } + \chk_if_free_cs:c { \c_msg_text_prefix_tl #1 :xxxx } \msg_generic_set:nnn {#1} } \cs_new_nopar:Npn \msg_generic_new:nn #1 { - \exp_args:Nc \chk_if_free_cs:N { \c_msg_text_prefix_tl #1 :nn } + \chk_if_free_cs:c { \c_msg_text_prefix_tl #1 :xxxx } \msg_generic_set:nn {#1} } -\cs_new_nopar:Npn \msg_generic_set:nnnn #1 { - \msg_generic_set_clist:n {#1} - \char_make_space:N \ % - \msg_generic_set_code:nnnn{#1}% -} \cs_new_nopar:Npn \msg_generic_set:nnn #1 { \msg_generic_set_clist:n {#1} - \char_make_space:N \ % - \msg_generic_set_more_text:nnn{#1}% + \char_make_space:N \ + \msg_generic_set_more_text:nnn {#1} } \cs_new_nopar:Npn \msg_generic_set:nn #1 { \msg_generic_set_clist:n {#1} - \char_make_space:N \ % - \msg_generic_set_text:nn{#1}% + \char_make_space:N \ + \msg_generic_set_text:nn {#1} } \cs_new_nopar:Npn \msg_generic_set_clist:n #1 { \clist_if_in:NnF \l_msg_names_clist { // #1 / } { \clist_put_right:Nn \l_msg_names_clist { // #1 / } } } -\cs_new:Nn \msg_generic_set_text:nn { - \cs_set:cn { \c_msg_text_prefix_tl #1 :nn } {#2} - \char_make_ignore:N \ -} -\cs_new:Nn \msg_generic_set_more_text:nnn { - \cs_set:cn { \c_msg_text_prefix_tl #1 :nn } {#2} - \tl_if_empty:nTF {#3} { - \cs_set_eq:cN { \c_msg_more_text_prefix_tl #1 } \c_undefined - }{ - \cs_set:cn { \c_msg_more_text_prefix_tl #1 :nn } {#3} - } +\cs_new:Npn \msg_generic_set_text:nn #1#2 { + \cs_set:cpn { \c_msg_text_prefix_tl #1 :xxxx } ##1##2##3##4 {#2} + \cs_set_eq:cN { \c_msg_more_text_prefix_tl #1 :xxxx } \c_undefined \char_make_ignore:N \ } -\cs_new:Npn \msg_generic_set_code:nnnn #1#2#3 { - \cs_set:cn { \c_msg_text_prefix_tl #1 :nn } {#2} - \tl_if_empty:nTF {#3} { - \cs_set_eq:cN { \c_msg_more_text_prefix_tl #1 } \c_undefined - }{ - \cs_set:cn { \c_msg_more_text_prefix_tl #1 :nn } {#3} - } +\cs_new:Npn \msg_generic_set_more_text:nnn #1#2#3 { + \cs_set:cpn { \c_msg_text_prefix_tl #1 :xxxx } ##1##2##3##4 {#2} + \cs_set:cpn { \c_msg_more_text_prefix_tl #1 :xxxx } ##1##2##3##4 {#3} \char_make_ignore:N \ - \msg_generic_set_code:nn {#1} -} -\cs_new:Nn \msg_generic_set_code:nn { - \tl_if_empty:nTF {#2} { - \cs_set_eq:cN { \c_msg_code_prefix_tl #1 : } \c_undefined - }{ - \cs_set:cn { \c_msg_code_prefix_tl #1 : } {#2} - } } \group_begin: \char_set_lccode:nn {`\&} {`\ } % { @@ -185,7 +156,7 @@ \char_make_letter:N\ % \tl_to_lowercase:n{% \group_end:% -\cs_new_protected:Nn\msg_direct_interrupt:xxxxn{% +\cs_new_protected:Npn\msg_direct_interrupt:xxxx#1#2#3#4{% \group_begin:% \cs_set_eq:NN\\\msg_newline:% \cs_set_eq:NN\ \msg_space:% @@ -202,42 +173,35 @@ }% &% \group_end:% -#5% }% }% -\cs_new:Nn \msg_direct_interrupt_aux:n { +\cs_new:Npn \msg_direct_interrupt_aux:n #1 { \tl_if_empty:nTF {#1} { \tl_set:Nx \l_msg_tmp_tl { { \c_msg_no_info_text_tl } } }{ - \tl_set:Nx \l_msg_tmp_tl { {#1 } } + \tl_set:Nx \l_msg_tmp_tl { {#1} } } } -\cs_new_protected:Nn \msg_direct_log:xx { +\cs_new_protected:Npn \msg_direct_log:xx #1#2 { \group_begin: \cs_set:Npn \\ { \msg_newline: #2 } \cs_set_eq:NN \ \msg_space: \iow_log:x { #1 \msg_newline: } \group_end: } -\cs_new_protected:Nn \msg_direct_term:xx { +\cs_new_protected:Npn \msg_direct_term:xx #1#2 { \group_begin: \cs_set:Npn \\ { \msg_newline: #2 } \cs_set_eq:NN \ \msg_space: \iow_term:x { #1 \msg_newline: } \group_end: } -\cs_new_nopar:Npn \msg_new:nnnnn #1#2 { - \msg_generic_new:nnnn { #1 / #2 } -} \cs_new_nopar:Npn \msg_new:nnnn #1#2 { \msg_generic_new:nnn { #1 / #2 } } \cs_new_nopar:Npn \msg_new:nnn #1#2 { \msg_generic_new:nn { #1 / #2 } } -\cs_new_nopar:Npn \msg_set:nnnnn #1#2 { - \msg_generic_set:nnnn { #1 / #2 } -} \cs_new_nopar:Npn \msg_set:nnnn #1#2 { \msg_generic_set:nnn { #1 / #2 } } @@ -245,48 +209,54 @@ \msg_generic_set:nn { #1 / #2 } } \cs_new_nopar:Npn \msg_class_new:nn #1 { - \exp_args:Nc \chk_if_free_cs:N { msg_ #1 :nnxx } + \chk_if_free_cs:c { msg_ #1 :nnxxxx } \prop_new:c { l_msg_redirect_ #1 _prop } \msg_class_set:nn {#1} } -\cs_new_nopar:Nn \msg_class_set:nn { +\cs_new_nopar:Npn \msg_class_set:nn #1#2 { \prop_clear:c { l_msg_redirect_ #1 _prop } - \cs_set_protected:cn { msg_ #1 :nnxx } { - \msg_use:nnnnxx {#1} {#2} {##1} {##2} {##3} {##4} + \cs_set_protected:cpn { msg_ #1 :nnxxxx } ##1##2##3##4##5##6 { + \msg_use:nnnnxxxx {#1} {#2} {##1} {##2} {##3} {##4} {##5} {##6} + } + \cs_set_protected:cpx { msg_ #1 :nnxxx } ##1##2##3##4##5 { + \exp_not:c { msg_ #1 :nnxxxx } {##1} {##2} {##3} {##4} {##5} { } } - \cs_set_protected:cn { msg_ #1 :nnx } { - \use:c { msg_ #1 :nnxx } {##1} {##2} {##3} { } + \cs_set_protected:cpx { msg_ #1 :nnxx } ##1##2##3##4 { + \exp_not:c { msg_ #1 :nnxxxx } {##1} {##2} {##3} {##4} { } { } } - \cs_set_protected:cn { msg_ #1 :nn } { - \use:c { msg_ #1 :nnxx } {##1} {##2} { } { } + \cs_set_protected:cpx { msg_ #1 :nnx } ##1##2##3 { + \exp_not:c { msg_ #1 :nnxxxx } {##1} {##2} {##3} { } { } { } + } + \cs_set_protected:cpx { msg_ #1 :nn } ##1##2 { + \exp_not:c { msg_ #1 :nnxxxx } {##1} {##2} { } { } { } { } } } -\cs_new:Nn \msg_use:nnnnxx { - \cs_set:Nn \msg_use_code: { +\cs_new:Npn \msg_use:nnnnxxxx #1#2#3#4#5#6#7#8 { + \cs_set_nopar:Npn \msg_use_code: { \clist_clear:N \l_msg_redirect_classes_clist #2 } - \cs_set:Nn \msg_use_loop:n { + \cs_set:Npn \msg_use_loop:n ##1 { \clist_if_in:NnTF \l_msg_redirect_classes_clist {#1} { - \msg_kernel_error:n { message-loop } + \msg_kernel_error:nn { msg } { redirect-loop } {#1} }{ \clist_put_right:Nn \l_msg_redirect_classes_clist {#1} - \cs_if_exist:cTF { msg_ ##1 :nnxx } { - \use:c { msg_ ##1 :nnxx } {#3} {#4} {#5} {#6} + \cs_if_exist:cTF { msg_ ##1 :nnxxxx } { + \use:c { msg_ ##1 :nnxxxx } {#3} {#4} {#5} {#6} {#7} {#8} }{ - \msg_kernel_error:nx { message-class-unknown } { ##1 } + \msg_kernel_error:nnx { msg } { message-class-unknown } {##1} } } } - \cs_if_exist:cTF { \c_msg_text_prefix_tl #3 / #4 :nn } { + \cs_if_exist:cTF { \c_msg_text_prefix_tl #3 / #4 :xxxx } { \msg_use_aux:nnn {#1} {#3} {#4} }{ - \msg_kernel_error:nxx { message-unknown } { #3 } { #4 } + \msg_kernel_error:nnxx { msg } { message-unknown } {#3} {#4} } } -\cs_new_nopar:Nn \msg_use_code: { } -\cs_new_nopar:Nn \msg_use_loop:n { } -\cs_new_nopar:Nn \msg_use_aux:nnn { +\cs_new_nopar:Npn \msg_use_code: { } +\cs_new:Npn \msg_use_loop:n #1 { } +\cs_new_nopar:Npn \msg_use_aux:nnn #1#2#3 { \tl_set:Nn \l_msg_current_class_tl {#1} \tl_set:Nn \l_msg_current_module_tl {#2} \prop_if_in:NnTF \l_msg_redirect_names_prop { // #2 / #3 / } { @@ -295,18 +265,18 @@ \msg_use_aux:nn {#1} {#2} } } -\cs_new_nopar:Nn \msg_use_aux:nn { +\cs_new_nopar:Npn \msg_use_aux:nn #1#2 { \prop_if_in:cnTF { l_msg_redirect_ #1 _prop } {#2} { \msg_use_loop_check:nn {#1} {#2} }{ - \prop_if_in:cnTF { l_msg_redirect_ #1 _prop } {*} { - \msg_use_loop_check:nn {#1} {*} + \prop_if_in:cnTF { l_msg_redirect_ #1 _prop } { * } { + \msg_use_loop_check:nn {#1} { * } }{ \msg_use_code: } } } -\cs_new:Nn \msg_use_loop_check:nn { +\cs_new:Npn \msg_use_loop_check:nn #1#2 { \prop_get:cnN { l_msg_redirect_ #1 _prop } {#2} \l_msg_class_tl \tl_if_eq:NNTF \l_msg_current_class_tl \l_msg_class_tl { \msg_use_code: @@ -315,177 +285,172 @@ } } \msg_class_new:nn { fatal } { - \msg_direct_interrupt:xxxxn + \msg_direct_interrupt:xxxx { \c_msg_fatal_tl \msg_two_newlines: } { ( \c_msg_fatal_tl ) \msg_space: - \use:c { \c_msg_text_prefix_tl #1 / #2 :nn } {#3} {#4} + \use:c { \c_msg_text_prefix_tl #1 / #2 :xxxx } {#3} {#4} {#5} {#6} } { ( \c_msg_fatal_tl ) \msg_space: } { \c_msg_fatal_text_tl } - { \tex_end:D } + \tex_end:D } \msg_class_new:nn { error } { - \msg_direct_interrupt:xxxxn + \msg_direct_interrupt:xxxx { #1~\c_msg_error_tl \msg_newline: } { ( #1 ) \msg_space: - \use:c { \c_msg_text_prefix_tl #1 / #2 :nn } {#3} {#4} + \use:c { \c_msg_text_prefix_tl #1 / #2 :xxxx } {#3} {#4} {#5} {#6} } { ( #1 ) \msg_space: } { - \cs_if_exist:cTF { \c_msg_more_text_prefix_tl #1 / #2 :nn } { - \use:c { \c_msg_more_text_prefix_tl #1 / #2 :nn } {#3} {#4} - }{ - \c_msg_no_info_text_tl - } - } - { - \cs_if_exist:cT { \c_msg_code_prefix_tl #1 /#2 :nn } { - \use:c { \c_msg_code_prefix_tl #1 / #2 :nn} {#3} {#4} - } + \cs_if_exist:cTF { \c_msg_more_text_prefix_tl #1 / #2 :xxxx } + { + \use:c { \c_msg_more_text_prefix_tl #1 / #2 :xxxx } + {#3} {#4} {#5} {#6} + } + { \c_msg_no_info_text_tl } } } \msg_class_new:nn { warning } { \msg_direct_term:xx { - \msg_space: #1~\c_msg_warning_tl :~ - \use:c { \c_msg_text_prefix_tl #1 / #2 :nn } {#3} {#4} + \msg_space: #1 ~ \c_msg_warning_tl :~ + \use:c { \c_msg_text_prefix_tl #1 / #2 :xxxx } {#3} {#4} {#5} {#6} } { ( #1 ) \msg_two_spaces: } } \msg_class_new:nn { info } { \msg_direct_log:xx { \msg_space: #1~\c_msg_info_tl :~ - \use:c { \c_msg_text_prefix_tl #1 / #2 :nn } {#3} {#4} + \use:c { \c_msg_text_prefix_tl #1 / #2 :xxxx } {#3} {#4} {#5} {#6} } { ( #1 ) \msg_two_spaces: } } \msg_class_new:nn { log } { \msg_direct_log:xx { - \use:c { \c_msg_text_prefix_tl #1 / #2 :nn } {#3} {#4} + \use:c { \c_msg_text_prefix_tl #1 / #2 :xxxx } {#3} {#4} {#5} {#6} } { } } \msg_class_new:nn { trace } { \msg_direct_log:xx { - \use:c { \c_msg_text_prefix_tl #1 / #2 :nn } {#3} {#4} + \use:c { \c_msg_text_prefix_tl #1 / #2 :xxxx } {#3} {#4} {#5} {#6} } { } } \msg_class_new:nn { none } { } -\cs_new_nopar:Nn \msg_redirect_class:nn { - \prop_put:cnn { l_msg_redirect_ #1 _prop } {*} {#2} +\cs_new_nopar:Npn \msg_redirect_class:nn #1#2 { + \prop_put:cnn { l_msg_redirect_ #1 _prop } { * } {#2} } -\cs_new_nopar:Nn \msg_redirect_module:nnn { +\cs_new_nopar:Npn \msg_redirect_module:nnn #1#2#3 { \prop_put:cnn { l_msg_redirect_ #2 _prop } {#1} {#3} } -\cs_new_nopar:Nn \msg_redirect_name:nnn { +\cs_new_nopar:Npn \msg_redirect_name:nnn #1#2#3 { \prop_put:Nnn \l_msg_redirect_names_prop { // #1 / #2 / } {#3} } -\cs_new_nopar:Npn \msg_kernel_new:nnnn #1 { - \msg_new:nnnnn { LaTeX } {#1} -} -\cs_new_nopar:Npn \msg_kernel_new:nnn #1 { - \msg_new:nnnn { LaTeX } {#1} -} -\cs_new_nopar:Npn \msg_kernel_new:nn #1 { - \msg_new:nnn { LaTeX } {#1} +\cs_new_nopar:Npn \msg_kernel_new:nnnn #1#2 { + \msg_new:nnnn { LaTeX } { #1 / #2 } } -\cs_new_nopar:Npn \msg_kernel_set:nnnn #1 { - \msg_set:nnnnn { LaTeX } {#1} +\cs_new_nopar:Npn \msg_kernel_new:nnn #1#2 { + \msg_new:nnn { LaTeX } { #1 / #2 } } -\cs_new_nopar:Npn \msg_kernel_set:nnn #1 { - \msg_set:nnnn { LaTeX } {#1} +\cs_new_nopar:Npn \msg_kernel_set:nnnn #1#2 { + \msg_set:nnnn { LaTeX } { #1 / #2 } } -\cs_new_nopar:Npn \msg_kernel_set:nn #1 { - \msg_set:nnn { LaTeX } {#1} +\cs_new_nopar:Npn \msg_kernel_set:nnn #1#2 { + \msg_set:nnn { LaTeX } { #1 / #2 } } -\cs_new_nopar:Nn \msg_kernel_classes_new:n { - \cs_new_protected:cn { msg_kernel_ #1 :nx } { - \use:c { msg_kernel_ #1 :nxx } {##1} {##2} { } +\cs_new_nopar:Npn \msg_kernel_classes_new:n #1 { + \cs_new_protected:cpx { msg_kernel_ #1 :nnxxx } ##1##2##3##4##5 + { + \exp_not:c { msg_kernel_ #1 :nnxxxx } + {##1} {##2} {##3} {##4} {##5} { } + } + \cs_new_protected:cpx { msg_kernel_ #1 :nnxx } ##1##2##3##4 + { + \exp_not:c { msg_kernel_ #1 :nnxxxx } + {##1} {##2} {##3} {##4} { } { } + } + \cs_new_protected:cpx { msg_kernel_ #1 :nnx } ##1##2##3 + { + \exp_not:c { msg_kernel_ #1 :nnxxxx } {##1} {##2} {##3} { } { } { } } - \cs_new_protected:cn { msg_kernel_ #1 :n } { - \use:c { msg_kernel_ #1 :nxx } {##1} { } { } + \cs_new_protected:cpx { msg_kernel_ #1 :nn } ##1##2 + { + \exp_not:c { msg_kernel_ #1 :nnxxxx } {##1} {##2} { } { } { } { } } } -\cs_new_protected:Nn \msg_kernel_fatal:nxx { - \msg_direct_interrupt:xxxxn +\cs_new_protected:Npn \msg_kernel_fatal:nnxxxx #1#2#3#4#5#6 { + \msg_direct_interrupt:xxxx { \c_msg_fatal_tl \msg_two_newlines: } { ( LaTeX ) \msg_space: - \use:c { \c_msg_text_prefix_tl LaTeX / #1 :nn } {#2} {#3} + \use:c { \c_msg_text_prefix_tl LaTeX / #1 / #2 :xxxx } + {#3} {#4} {#5} {#6} } { ( LaTeX ) \msg_space: } { \c_msg_fatal_text_tl } - { \tex_end:D } + \tex_end:D } \msg_kernel_classes_new:n { fatal } -\cs_new_protected:Nn \msg_kernel_error:nxx { - \msg_direct_interrupt:xxxxn +\cs_new_protected:Npn \msg_kernel_error:nnxxxx #1#2#3#4#5#6 { + \msg_direct_interrupt:xxxx { LaTeX~\c_msg_error_tl \msg_newline: } { ( LaTeX ) \msg_space: - \use:c { \c_msg_text_prefix_tl LaTeX / #1 :nn } {#2} {#3} + \use:c { \c_msg_text_prefix_tl LaTeX / #1 / #2 :xxxx } + {#3} {#4} {#5} {#6} } { ( LaTeX ) \msg_space: } { - \cs_if_exist:cTF { \c_msg_more_text_prefix_tl LaTeX / #1 :nn } { - \use:c { \c_msg_more_text_prefix_tl LaTeX / #1 :nn } {#2} {#3} - }{ - \c_msg_no_info_text_tl - } - } - { - \cs_if_exist:cT { \c_msg_code_prefix_tl LaTeX /#1 :nn } { - \use:c { \c_msg_code_prefix_tl LaTeX / #1 :nn} {#2} {#3} - } + \cs_if_exist:cTF + { \c_msg_more_text_prefix_tl LaTeX / #1 / #2 :xxxx } + { + \use:c { \c_msg_more_text_prefix_tl LaTeX / #1 / #2 :xxxx } + {#3} {#4} {#5} {#6} + } + { \c_msg_no_info_text_tl } } } \msg_kernel_classes_new:n { error } -\cs_new_protected_nopar:Npn \msg_kernel_warning:nxx { - \msg_warning:nnxx { LaTeX } +\cs_new_protected_nopar:Npn \msg_kernel_warning:nnxxxx #1#2 { + \msg_warning:nnxxxx { LaTeX } { #1 / #2 } } \msg_kernel_classes_new:n { warning } -\cs_new_protected_nopar:Npn \msg_kernel_info:nxx { - \msg_info:nnxx { LaTeX } +\cs_new_protected_nopar:Npn \msg_kernel_info:nnxxxx #1#2 { + \msg_info:nnxxxx { LaTeX } { #1 / #2 } } \msg_kernel_classes_new:n { info } -\msg_kernel_new:nnn { coding-bug } {% - This is a LaTeX bug: check coding!\\% - #1% -}{% - #2% -} -\msg_kernel_new:nnn { message-unknown } {% - Unknown message `#2' for module `#1'.% -}{% - LaTeX was asked to display a message by the `#1' module.\\% - The message was supposed to be called `#2', but I can't\\% - find a message with that name. - \c_msg_return_text_tl -} -\msg_kernel_new:nnn { message-class-unknown } {% - Unknown message class `#1'.% -}{% - You have asked for a message to be redirected to class `#1'\\% - but this class is unknown. - \c_msg_return_text_tl -} -\msg_kernel_new:nnn { message-loop } {% - Message redirection loop.% -}{% - You have asked for a message to be redirected,\\% - but the redirection instructions form a loop:\\% - you've lost the message. - \c_msg_return_text_tl -} -\cs_set_protected:Nn \msg_kernel_bug:x { - \msg_direct_interrupt:xxxxn +\msg_kernel_new:nnnn { msg } { message-unknown } + {Unknown message `#2' for module `#1'.} + {% + LaTeX was asked to display a message by the `#1' module.\\% + The message was supposed to be called `#2', but I can't\\% + find a message with that name.% + \c_msg_return_text_tl + } +\msg_kernel_new:nnnn { msg } { message-class-unknown } + {Unknown message class `#1'.} + {% + You have asked for a message to be redirected to class `#1'.\\% + The message class `#1' has not been set up:\\% + perhaps this is a typing error.% + \c_msg_return_text_tl + } +\msg_kernel_new:nnnn { msg } { redirect-loop } + {Message redirection loop for message class `#1'.} + {% + You have asked for a message to be redirected,\\% + but the redirection instructions form a loop:\\% + you've lost the message.% + \c_msg_return_text_tl + } +\cs_set_protected:Npn \msg_kernel_bug:x #1 { + \msg_direct_interrupt:xxxx { \c_msg_kernel_bug_text_tl } { !~#1 } { ! } { \c_msg_kernel_bug_more_text_tl } - { } } %% %% |