summaryrefslogtreecommitdiff
path: root/macros/latex-dev/base/ltcmd.dtx
diff options
context:
space:
mode:
authorNorbert Preining <norbert@preining.info>2021-05-05 03:02:17 +0000
committerNorbert Preining <norbert@preining.info>2021-05-05 03:02:17 +0000
commit75db33dc347ec9cfbaa2f3ec538a2697351f571b (patch)
tree0ea6d721f8478ed9ae95c93330c94aa8fcfd30b8 /macros/latex-dev/base/ltcmd.dtx
parent342f2e1be699f5ec70b5b1c35d9cd59798d37304 (diff)
CTAN sync 202105050302
Diffstat (limited to 'macros/latex-dev/base/ltcmd.dtx')
-rw-r--r--macros/latex-dev/base/ltcmd.dtx68
1 files changed, 30 insertions, 38 deletions
diff --git a/macros/latex-dev/base/ltcmd.dtx b/macros/latex-dev/base/ltcmd.dtx
index 26ce75224f..fee555586d 100644
--- a/macros/latex-dev/base/ltcmd.dtx
+++ b/macros/latex-dev/base/ltcmd.dtx
@@ -34,14 +34,15 @@
%%% From File: ltcmd.dtx
%
% \begin{macrocode}
-\def\ltcmdversion{v1.0a}
-\def\ltcmddate{2021/01/21}
+\def\ltcmdversion{v1.0d}
+\def\ltcmddate{2021-04-19}
% \end{macrocode}
%
%<*driver>
% \fi
\ProvidesFile{ltcmd.dtx}
- [2020-11-20 v1.0 LaTeX Kernel (Document commands)]
+ [\ltcmddate\space \ltcmdversion\space
+ LaTeX Kernel (Document commands)]
% \iffalse
\documentclass{l3doc}
\GetFileInfo{ltcmd.dtx}
@@ -57,7 +58,7 @@
%
% \section{Creating document commands}
%
-% \changes{v1.0}{2020-11-20}{Initial version derived from \texttt{xparse.dtx}}
+% \changes{v1.0a}{2020/11/20}{Initial version derived from \texttt{xparse.dtx}}
%
% Document commands should be created using the tools provided by this module:
% \cs{NewDocumentCommand}, etc.\@, in almost all cases. This allows clean
@@ -78,6 +79,7 @@
%</2ekernel>
% \end{macrocode}
%
+% \changes{v1.0b}{2021/03/18}{Use \cs{NewModuleRelease}.}
% \pkg{ltcmd} code contains an |^^@| character, which usually has
% catcode~15, so \cs{IncludeInRelease} will break when this code is
% being skipped, so we'll save the catcode of |^^@| to restore later:
@@ -85,12 +87,9 @@
%<*2ekernel|latexrelease>
%<latexrelease>\edef\@latexrelease@catcode@null{\the\catcode`\^^@ }
%<latexrelease>\catcode`\^^@=12
-%<latexrelease>\IncludeInRelease{2021/05/01}%
-%<latexrelease> {\NewDocumentCommand}{Document commands}%
-% \end{macrocode}
-%
-% \begin{macrocode}
\ExplSyntaxOn
+%<latexrelease>\NewModuleRelease{2020/10/01}{ltcmd}
+%<latexrelease> {Document~command~parser}%
% \end{macrocode}
%
% \subsection{Variables and constants}
@@ -3196,7 +3195,7 @@
% \begin{macrocode}
\cs_new_protected:Npn \@@_get_arg_spec:NTF #1#2#3
{
- \@@_cmd_if_xparse:NTF #1
+ \__kernel_cmd_if_xparse:NTF #1
{
\tl_set:Nx \ArgumentSpecification { \tl_item:Nn #1 { 2 } }
#2
@@ -3374,15 +3373,22 @@
% \end{macro}
% \end{macro}
%
-% \begin{macro}{\@@_cmd_if_xparse:NTF}
+% \begin{macro}{\__kernel_cmd_if_xparse:NTF}
+% \changes{v1.0d}{2021/04/19}{Renamed \cs{__cmd_cmd_if_xparse:NTF} to
+% \cs{__kernel_cmd_if_xparse:NTF} for cross-module usage}
% \begin{macro}{\@@_cmd_if_xparse_aux:N}
-% To determine whether the command is an \pkg{xparse} command check
-% that its |arg_spec| is empty (this also excludes non-macros) and
-% that its |replacement_spec| starts with either \cs{@@_start:nNNnnn}
-% (non-expandable command) or \cs{@@_start_expandable:nNNNNn}
-% (expandable command) or \cs{@@_start_env:nnnnn} (environment).
+%
+% To determine whether the command is an \pkg{xparse} command check
+% that its |arg_spec| is empty (this also excludes non-macros) and
+% that its |replacement_spec| starts with either
+% \cs{@@_start:nNNnnn} (non-expandable command) or
+% \cs{@@_start_expandable:nNNNNn} (expandable command) or
+% \cs{@@_start_env:nnnnn} (environment).
+%
+% This conditional is needed in several kernel modules and is
+% therefore has a kernel-internal name.
% \begin{macrocode}
-\cs_new_protected:Npn \@@_cmd_if_xparse:NTF #1
+\cs_new_protected:Npn \__kernel_cmd_if_xparse:NTF #1
{
\exp_args:Nf \str_case_e:nnTF
{
@@ -4008,29 +4014,15 @@
% \end{macrocode}
%
% \begin{macrocode}
-\ExplSyntaxOff
-% \end{macrocode}
-%
-% \begin{macrocode}
-%</2ekernel|latexrelease>
-%<latexrelease>\EndIncludeInRelease
-%<latexrelease>\catcode`\^^@=\@latexrelease@catcode@null\relax
-%<latexrelease>
-%<latexrelease>\IncludeInRelease{2020/10/01}%
-%<latexrelease> {\NewDocumentCommand}{Document commands}%
-%<latexrelease>\@ifundefined{NewDocumentCommand}
-%<latexrelease> {%
-%<latexrelease> \IfFileExists{xparse.ltx}
-%<latexrelease> {\input xparse.ltx }
-%<latexrelease> {\@latex@error{LaTeX requires xparse}\@ehd}%
-%<latexrelease> }
-%<latexrelease> {}
-%<latexrelease>\EndIncludeInRelease
%<latexrelease>
-%<latexrelease>\IncludeInRelease{0000/00/00}%
-%<latexrelease> {\NewDocumentCommand}{Document commands}%
+%<latexrelease>\IncludeInRelease{0000/00/00}{ltcmd}%
+%<latexrelease> {Document~command~parser}%
%<latexrelease>
-%<latexrelease>\EndIncludeInRelease
+%<latexrelease>\EndModuleRelease
+\ExplSyntaxOff
+%<latexrelease>\@ifundefined{ExplSyntaxOff}{}{\latexrelease@postexpl}
+%<latexrelease>\catcode`\^^@=\@latexrelease@catcode@null\relax
+%</2ekernel|latexrelease>
% \end{macrocode}
%
% We need to stop DocStrip treating |@@| in a special way at this point.