[latex3-commits] [git/LaTeX3-latex3-latex2e] cmd: Disable new command checking with latexrelease (11cdbcb5)

PhelypeOleinik phelype.oleinik at latex-project.org
Wed Jan 27 02:15:32 CET 2021


Repository : https://github.com/latex3/latex2e
On branch  : cmd
Link       : https://github.com/latex3/latex2e/commit/11cdbcb5b00b87deca3fb3aefd18d0f6788232bd

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

commit 11cdbcb5b00b87deca3fb3aefd18d0f6788232bd
Author: PhelypeOleinik <phelype.oleinik at latex-project.org>
Date:   Tue Jan 26 22:15:32 2021 -0300

    Disable new command checking with latexrelease
    
    When rolling forward from 2020-10-01 (and very likely only if rolling to
    2021-05-01) there will be errors because the ltcmd module was introduced
    but the public commands are the same as the ones pre-loaded 2020-10-01,
    so this disables that checking temporarily for this specific case.


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

11cdbcb5b00b87deca3fb3aefd18d0f6788232bd
 base/ltcmd.dtx | 16 ++++++++++++++++
 1 file changed, 16 insertions(+)

diff --git a/base/ltcmd.dtx b/base/ltcmd.dtx
index 900cca83..96d82bb6 100644
--- a/base/ltcmd.dtx
+++ b/base/ltcmd.dtx
@@ -3206,6 +3206,16 @@
 %    \end{macrocode}
 % \end{macro}
 %
+% Rolling forward from 2020-10-01 is tricky because the entire |ltcmd|
+% module is new, but the user-level commands have the same name, so only
+% these will clash.  To work around that, in |latexrelease| mode we will
+% (temporarily) disable \cs{__kernel_chk_if_free_cs:N} for this final
+% part of the code, then restore at the end.
+%    \begin{macrocode}
+%<latexrelease>\cs_new_eq:NN \@@_chk_if_free_cs:N \__kernel_chk_if_free_cs:N
+%<latexrelease>\cs_gset_eq:NN \__kernel_chk_if_free_cs:N \use_none:n
+%    \end{macrocode}
+%
 % \begin{variable}{\ArgumentSpecification}
 %    \begin{macrocode}
 \tl_new:N \ArgumentSpecification
@@ -3991,6 +4001,12 @@
 % \end{macro}
 % \end{macro}
 %
+% Finally as promised, restore \cs{__kernel_chk_if_free_cs:N}:
+%    \begin{macrocode}
+%<latexrelease>\cs_gset_eq:NN \__kernel_chk_if_free_cs:N \@@_chk_if_free_cs:N
+%<latexrelease>\cs_undefine:N \@@_chk_if_free_cs:N
+%    \end{macrocode}
+%
 %    \begin{macrocode}
 \ExplSyntaxOff
 %    \end{macrocode}





More information about the latex3-commits mailing list.