summaryrefslogtreecommitdiff
path: root/macros/latex-dev/base/ltclass.dtx
diff options
context:
space:
mode:
authorNorbert Preining <norbert@preining.info>2023-05-26 03:02:08 +0000
committerNorbert Preining <norbert@preining.info>2023-05-26 03:02:08 +0000
commit8057c647880f05a2624b3d04ab0eb38d5cbf8c18 (patch)
tree2df10dbc859977e89de9b6797303c039106aca37 /macros/latex-dev/base/ltclass.dtx
parented4c98e3a1f3e2160094ac1b05cfc304832cce4d (diff)
CTAN sync 202305260302
Diffstat (limited to 'macros/latex-dev/base/ltclass.dtx')
-rw-r--r--macros/latex-dev/base/ltclass.dtx23
1 files changed, 22 insertions, 1 deletions
diff --git a/macros/latex-dev/base/ltclass.dtx b/macros/latex-dev/base/ltclass.dtx
index f6d5994d3f..bb52148508 100644
--- a/macros/latex-dev/base/ltclass.dtx
+++ b/macros/latex-dev/base/ltclass.dtx
@@ -33,7 +33,7 @@
%<*driver>
% \fi
\ProvidesFile{ltclass.dtx}
- [2022/11/16 v1.5f LaTeX Kernel (Class & Package Interface)]
+ [2023/04/14 v1.5h LaTeX Kernel (Class & Package Interface)]
% \iffalse
\documentclass{ltxdoc}
\GetFileInfo{ltclass.dtx}
@@ -324,6 +324,7 @@
%
% \DescribeMacro\IfPackageAtLeastTF
% \DescribeMacro\IfClassAtLeastTF
+% \DescribeMacro\IfFileAtLeastTF
% \DescribeMacro\@ifpackagelater
% \DescribeMacro\@ifclasslater
% \changes{v1.1i}{2013/07/07}{Correctly describe how the date in
@@ -890,12 +891,14 @@
%
% \begin{macro}{\IfPackageAtLeastTF}
% \begin{macro}{\IfClassAtLeastTF}
+% \begin{macro}{\IfFileAtLeastTF}
% \begin{macro}{\IfFormatAtLeastTF}
% |\IfFormatAtLeastTF{YYYY/MM/DD}{|\meta{true
% code}|}{|\meta{false code}|}|
% Test if the format is later or equal to the given date.
% \changes{v1.3k}{2020/04/07}{Macro added; also in rollback (gh/168)}
% \changes{v1.4e}{2021/07/19}{Drop \cs{@onlypreamble}}
+% \changes{v1.5g}{2023/03/28}{Added \cs{IfFileAtLeastTF} (gh/1015)}
% \begin{macrocode}
%</2ekernel>
%<*2ekernel|latexrelease>
@@ -904,6 +907,7 @@
\def\IfFormatAtLeastTF{\@ifl@t@r\fmtversion}
\let\IfPackageAtLeastTF\@ifpackagelater
\let\IfClassAtLeastTF\@ifclasslater
+\def\IfFileAtLeastTF#1{\expandafter\@ifl@t@r\csname ver@#1\endcsname}
% \end{macrocode}
% For rollback pretend it was available since the beginning of dawn.
% \begin{macrocode}
@@ -914,12 +918,14 @@
%<latexrelease>\def\IfFormatAtLeastTF{\@ifl@t@r\fmtversion}
%<latexrelease>\let\IfPackageAtLeastTF\@ifpackagelater
%<latexrelease>\let\IfClassAtLeastTF\@ifclasslater
+%<latexrelease>\def\IfFileAtLeastTF#1{\expandafter\@ifl@t@r\csname ver@#1\endcsname}
%<latexrelease>\EndIncludeInRelease
%<*2ekernel>
% \end{macrocode}
% \end{macro}
% \end{macro}
% \end{macro}
+% \end{macro}
%
% \begin{macro}{\@ifl@ter}
% \changes{v1.4e}{2021/07/19}{Drop \cs{@onlypreamble}}
@@ -2133,13 +2139,28 @@
% {Reset \cs{CurrentOption}}
% \changes{v1.3d}{2019/10/18}{Initialize \cs{...-h@@k} only when loading
% the package or class (gh/198)}
+% \changes{v1.5h}{2023/04/14}{Define \cs{load@onefilewithoptions} when
+% in \pkg{latexrelease} (gh/992)}
% \begin{macrocode}
%</2ekernel>
%<*2ekernel|latexrelease>
%<latexrelease>\IncludeInRelease{2020/10/01}%
%<latexrelease> {\@onefilewithoptions}{Hooks and unused options issue}%
+% \end{macrocode}
+%
+% Here this macro is called \cs{@onefilewithoptions}, but further
+% ahead in this file it is renamed to \cs{load@onefilewithoptions},
+% and \cs{@onefilewithoptions} becomes a wrapper around this, used for
+% bookkeeping when rolling back. Therefore, when in
+% \pkg{latexrelease}, we need to define \cs{load@onefilewithoptions}
+% instead, thus the extra guarded \cs{def} line below:
+% \begin{macrocode}
+%<*2ekernel>
\def\@onefilewithoptions#1[#2][#3]#4{%
+%</2ekernel>
+%<latexrelease>\def\load@onefilewithoptions#1[#2][#3]#4{%
% \end{macrocode}
+%
% We have to sanitise file names, so that something like
% \begin{verbatim}
% \usepackage{some/local/path/array}