[latex3-commits] [git/LaTeX3-latex3-latex3] main: Rename \cs_argument_spec:N to \cs_parameter_spec:N (24b19a75e)

Joseph Wright joseph.wright at morningstar2.co.uk
Fri Jun 24 15:27:33 CEST 2022


Repository : https://github.com/latex3/latex3
On branch  : main
Link       : https://github.com/latex3/latex3/commit/24b19a75edac8cbd9d3acf458946d5fb9094e7b2

>---------------------------------------------------------------

commit 24b19a75edac8cbd9d3acf458946d5fb9094e7b2
Author: Joseph Wright <joseph.wright at morningstar2.co.uk>
Date:   Fri Jun 24 14:27:33 2022 +0100

    Rename \cs_argument_spec:N to \cs_parameter_spec:N
    
    This fixes #1066 - as well as the rename there is work to
    tidy up the docs.


>---------------------------------------------------------------

24b19a75edac8cbd9d3acf458946d5fb9094e7b2
 l3kernel/CHANGELOG.md             |  6 ++++++
 l3kernel/doc/l3obsolete.txt       |  1 +
 l3kernel/l3basics.dtx             | 18 +++++++++---------
 l3kernel/l3debug.dtx              |  4 ++--
 l3kernel/l3deprecation.dtx        | 13 +++++++++++++
 l3kernel/l3tl.dtx                 |  4 ++--
 l3kernel/testfiles/m3token002.lvt |  4 ++--
 l3trial/l3check/l3check.dtx       |  2 +-
 8 files changed, 36 insertions(+), 16 deletions(-)

diff --git a/l3kernel/CHANGELOG.md b/l3kernel/CHANGELOG.md
index 7141b0226..48077ec63 100644
--- a/l3kernel/CHANGELOG.md
+++ b/l3kernel/CHANGELOG.md
@@ -7,6 +7,12 @@ this project uses date-based 'snapshot' version identifiers.
 
 ## [Unreleased]
 
+### Added
+- `\cs_parameter_spec:N`
+
+### Deprecated
+- `\cs_argument_spec:N`
+
 ### Fixed
 - Correct validity check performed by `\regex_show:N` (gh/1093)
 
diff --git a/l3kernel/doc/l3obsolete.txt b/l3kernel/doc/l3obsolete.txt
index ec9ae7a88..6f8844ce6 100644
--- a/l3kernel/doc/l3obsolete.txt
+++ b/l3kernel/doc/l3obsolete.txt
@@ -22,6 +22,7 @@ Function                            Date deprecated
 \char_str_lower_case:N                   2020-01-03
 \char_str_mixed_case:N                   2020-01-03
 \char_str_upper_case:N                   2020-01-03
+\cs_argument_spec:N                      2022-06-24
 \l_keys_key_tl                           2020-02-08
 \l_keys_path_tl                          2020-02-08
 \peek_catcode_ignore_spaces:N            2022-01-11
diff --git a/l3kernel/l3basics.dtx b/l3kernel/l3basics.dtx
index 7f103c2e4..f37263585 100644
--- a/l3kernel/l3basics.dtx
+++ b/l3kernel/l3basics.dtx
@@ -850,22 +850,22 @@
 %   \end{texnote}
 % \end{function}
 %
-% \begin{function}[EXP, added = 2019-02-27]{\cs_argument_spec:N}
+% \begin{function}[EXP, added = 2022-06-24]{\cs_parameter_spec:N}
 %   \begin{syntax}
-%     \cs{cs_argument_spec:N} \meta{token}
+%     \cs{cs_parameter_spec:N} \meta{token}
 %   \end{syntax}
 %   If the \meta{token} is a macro, this function leaves the primitive
-%   \TeX{} argument specification in input stream as a string of
+%   \TeX{} parameter specification in input stream as a string of
 %   character tokens of category code $12$ (with spaces having category
 %   code $10$). Thus for example
 %   \begin{verbatim}
 %     \cs_set:Npn \next:nn #1#2 { x #1 y #2 }
-%     \cs_argument_spec:N \next:nn
+%     \cs_parameter_spec:N \next:nn
 %   \end{verbatim}
 %   leaves |#1#2| in the input stream. If the \meta{token} is
 %   not a macro then \cs{scan_stop:} is left in the input stream.
 %   \begin{texnote}
-%     If the argument specification contains the string |->|, then the
+%     If the parameter specification contains the string |->|, then the
 %     function produces incorrect results.
 %   \end{texnote}
 % \end{function}
@@ -884,7 +884,7 @@
 %   leaves \verb*|x#1 y#2| in the input stream. If the \meta{token} is
 %   not a macro then \cs{scan_stop:} is left in the input stream.
 %   \begin{texnote}
-%     If the argument specification contains the string |->|, then the
+%     If the parameter specification contains the string |->|, then the
 %     function produces incorrect results.
 %   \end{texnote}
 % \end{function}
@@ -3191,14 +3191,14 @@
 % \subsection{Decomposing a macro definition}
 %
 % \begin{macro}{\cs_prefix_spec:N}
-% \begin{macro}{\cs_argument_spec:N}
+% \begin{macro}{\cs_parameter_spec:N}
 % \begin{macro}{\cs_replacement_spec:N}
 % \begin{macro}{\@@_prefix_arg_replacement:wN}
 %   We sometimes want to test if a control sequence can be expanded to
 %   reveal a hidden value. However, we cannot just expand the macro
 %   blindly as it may have arguments and none might be
 %   present. Therefore we define these functions to pick either the
-%   prefix(es), the argument specification, or the replacement text from
+%   prefix(es), the parameter specification, or the replacement text from
 %   a macro. All of this information is returned as characters with
 %   catcode~$12$. If the token in question isn't a macro, the token
 %   \cs{scan_stop:} is returned instead.
@@ -3218,7 +3218,7 @@
       }
       { \scan_stop: }
   }
-\cs_new:Npn \cs_argument_spec:N #1
+\cs_new:Npn \cs_parameter_spec:N #1
   {
     \token_if_macro:NTF #1
       {
diff --git a/l3kernel/l3debug.dtx b/l3kernel/l3debug.dtx
index e890919a5..e0da4f04b 100644
--- a/l3kernel/l3debug.dtx
+++ b/l3kernel/l3debug.dtx
@@ -727,7 +727,7 @@
             {
               \tex_global:D \cs_prefix_spec:N #1
               \tex_def:D \exp_not:N #1
-              \cs_argument_spec:N #1
+              \cs_parameter_spec:N #1
                 {
                   \tl_to_str:n {#2}
                   \cs_replacement_spec:N #1
@@ -1155,7 +1155,7 @@
         \exp_args:Nx \tex_scantokens:D
           {
             \tex_global:D \cs_prefix_spec:N #1 \tex_def:D \exp_not:N #1
-              \cs_argument_spec:N #1
+              \cs_parameter_spec:N #1
               { \exp_args:No \tl_to_str:n { #1 #2 } }
           }
       \group_end:
diff --git a/l3kernel/l3deprecation.dtx b/l3kernel/l3deprecation.dtx
index ae32854e8..36e53da42 100644
--- a/l3kernel/l3deprecation.dtx
+++ b/l3kernel/l3deprecation.dtx
@@ -432,6 +432,19 @@
 %    \end{macrocode}
 % \end{macro}
 %
+% \subsection{Deprecated \pkg{l3basics} functions}
+%
+%    \begin{macrocode}
+%<@@=cs>
+%    \end{macrocode}
+%
+% \begin{macro}[EXP]{\cs_argument_spec:N}
+%    \begin{macrocode}
+\__kernel_patch_deprecation:nnNNpn { 2022-06-24 } { \cs_argument_spec:N }
+\cs_gset:Npn \cs_argument_spec:N { \cs_parameter_spec:N }
+%    \end{macrocode}
+% \end{macro}
+%
 % \subsection{Deprecated \pkg{l3str} functions}
 %
 %    \begin{macrocode}
diff --git a/l3kernel/l3tl.dtx b/l3kernel/l3tl.dtx
index d85b6b2a4..2f00437a6 100644
--- a/l3kernel/l3tl.dtx
+++ b/l3kernel/l3tl.dtx
@@ -3577,7 +3577,7 @@
     \__kernel_chk_defined:NT #2
       {
         \exp_args:Nf \tl_if_empty:nTF
-          { \cs_prefix_spec:N #2 \cs_argument_spec:N #2 }
+          { \cs_prefix_spec:N #2 \cs_parameter_spec:N #2 }
           {
             \exp_args:Ne #1
               { \token_to_str:N #2 = \__kernel_exp_not:w \exp_after:wN {#2} }
@@ -3651,7 +3651,7 @@
     \__kernel_chk_defined:NT #1
       {
         \exp_args:Nf \tl_if_empty:nTF
-          { \cs_prefix_spec:N #1 \cs_argument_spec:N #1 }
+          { \cs_prefix_spec:N #1 \cs_parameter_spec:N #1 }
           {
             \tl_set:Nx \l_@@_internal_a_tl {#3}
             \tl_if_eq:NNTF #1 \l_@@_internal_a_tl
diff --git a/l3kernel/testfiles/m3token002.lvt b/l3kernel/testfiles/m3token002.lvt
index 256707ae8..cb4ee76c8 100644
--- a/l3kernel/testfiles/m3token002.lvt
+++ b/l3kernel/testfiles/m3token002.lvt
@@ -346,10 +346,10 @@
 \cs_set_protected:Npn \tmpB #1 / #2 { #1 ## #2 }
 \TESTEXP{cs_~_spec}{
   \cs_prefix_spec:N      \tmpA \NEWLINE
-  \cs_argument_spec:N         \tmpA \NEWLINE
+  \cs_parameter_spec:N         \tmpA \NEWLINE
   \cs_replacement_spec:N \tmpA \NEWLINE \NEWLINE
   \cs_prefix_spec:N      \tmpB \NEWLINE
-  \cs_argument_spec:N         \tmpB \NEWLINE
+  \cs_parameter_spec:N         \tmpB \NEWLINE
   \cs_replacement_spec:N \tmpB \NEWLINE
 }
 
diff --git a/l3trial/l3check/l3check.dtx b/l3trial/l3check/l3check.dtx
index a396997ad..35b4fd44a 100644
--- a/l3trial/l3check/l3check.dtx
+++ b/l3trial/l3check/l3check.dtx
@@ -451,7 +451,7 @@
     \tl_if_empty:fTF
       {
         \cs_prefix_spec:N #1
-        \cs_argument_spec:N #1
+        \cs_parameter_spec:N #1
       }
       { \prg_return_true: }
       { \prg_return_false: }





More information about the latex3-commits mailing list.