summaryrefslogtreecommitdiff
path: root/macros/latex-dev/base/ltfiles.dtx
diff options
context:
space:
mode:
Diffstat (limited to 'macros/latex-dev/base/ltfiles.dtx')
-rw-r--r--macros/latex-dev/base/ltfiles.dtx15
1 files changed, 8 insertions, 7 deletions
diff --git a/macros/latex-dev/base/ltfiles.dtx b/macros/latex-dev/base/ltfiles.dtx
index 7d628f52e1..afb085a417 100644
--- a/macros/latex-dev/base/ltfiles.dtx
+++ b/macros/latex-dev/base/ltfiles.dtx
@@ -1,6 +1,6 @@
% \iffalse meta-comment
%
-% Copyright 1993-2019
+% Copyright (C) 1993-2019
% The LaTeX3 Project and any individual authors listed elsewhere
% in this file.
%
@@ -13,7 +13,7 @@
% The latest version of this license is in
% https://www.latex-project.org/lppl.txt
% and version 1.3c or later is part of all distributions of LaTeX
-% version 2005/12/01 or later.
+% version 2008 or later.
%
% This file has the LPPL maintenance status "maintained".
%
@@ -32,7 +32,7 @@
%<*driver>
% \fi
\ProvidesFile{ltfiles.dtx}
- [2019/07/01 v1.2a LaTeX Kernel (File Handling)]
+ [2019/08/27 v1.2b LaTeX Kernel (File Handling)]
% \iffalse
\documentclass{ltxdoc}
\GetFileInfo{ltfiles.dtx}
@@ -750,8 +750,9 @@
% \begin{macro}{\IfFileExists}
%
% \changes{v1.2a}{2019/07/01}{Support UTF-8}
+% \changes{v1.2b}{2019/08/27}{Make command robust}
% \begin{macrocode}
-\def\IfFileExists#1{%
+\DeclareRobustCommand\IfFileExists[1]{%
\set@curr@file{#1}%
\edef\q@curr@file{\expandafter\quote@name\expandafter{\@curr@file}}%
\expandafter\IfFileExists@\expandafter{\q@curr@file}}
@@ -761,8 +762,7 @@
% \begin{macro}{\IfFileExists@}
% \changes{v0.9b}{1993/12/04}{Macro added}
% \changes{v0.9p}{1994/01/18}{New Definition}
-% \changes{v1.0t}{1995/05/25}
-% {(CAR) added \cs{long}}
+% \changes{v1.0t}{1995/05/25}{(CAR) added \cs{long}}
%
% \begin{macrocode}
\long\def \IfFileExists@#1#2#3{%
@@ -857,13 +857,14 @@
% {(CAR) added \cs{long}}
% \changes{v1.1o}{2019/02/07}{Expand \cs{@filef@und} before executing
% second argument (github/109)}
+% \changes{v1.2b}{2019/08/27}{Make command robust}
% \begin{macrocode}
%</2ekernel>
%<latexrelease>\IncludeInRelease{2019/10/01}%
%<latexrelease> {\InputIfFileExists}{Don't lose the file name}%
%<*2ekernel|latexrelease>
% \begin{macrocode}
-\long\def \InputIfFileExists#1#2{%
+\DeclareRobustCommand \InputIfFileExists[2]{%
\IfFileExists{#1}%
{%
\expandafter\@swaptwoargs\expandafter