[latex3-commits] [git/LaTeX3-latex3-latex2e] hotfix/gh605: firstaid for #605 (5fb2860f)

Frank Mittelbach frank.mittelbach at latex-project.org
Mon Jun 28 14:54:09 CEST 2021


Repository : https://github.com/latex3/latex2e
On branch  : hotfix/gh605
Link       : https://github.com/latex3/latex2e/commit/5fb2860f2fedc87b213730f06ec1d77bcab4814a

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

commit 5fb2860f2fedc87b213730f06ec1d77bcab4814a
Author: Frank Mittelbach <frank.mittelbach at latex-project.org>
Date:   Mon Jun 28 14:54:09 2021 +0200

    firstaid for #605


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

5fb2860f2fedc87b213730f06ec1d77bcab4814a
 base/testfiles/tlb0406.luatex.tlg                  |  2 +-
 base/testfiles/tlb0406.tlg                         |  2 +-
 base/testfiles/tlb0942.luatex.tlg                  |  2 +-
 base/testfiles/tlb0942.tlg                         |  2 +-
 base/testfiles/tlb2558.luatex.tlg                  |  2 +-
 base/testfiles/tlb2558.tlg                         |  2 +-
 base/testfiles/tlb2558.xetex.tlg                   |  2 +-
 required/firstaid/changes.txt                      |  6 ++++
 .../latex2e-first-aid-for-external-files.dtx       | 34 ++++++++++++++++++++--
 9 files changed, 45 insertions(+), 9 deletions(-)

diff --git a/base/testfiles/tlb0406.luatex.tlg b/base/testfiles/tlb0406.luatex.tlg
index ad3fef19..ebd0e376 100644
--- a/base/testfiles/tlb0406.luatex.tlg
+++ b/base/testfiles/tlb0406.luatex.tlg
@@ -17,5 +17,5 @@ l. ...\DeclareMathSymbol{a}{7}{operators}{`\a}
 l. ...\DeclareMathSymbol{a}{7}{letters}{`\a}
 > 31457377.
 <to be read again> 
-\tex_par:D 
+\scan_stop: 
 l. ...
diff --git a/base/testfiles/tlb0406.tlg b/base/testfiles/tlb0406.tlg
index 9f32b6aa..8569f0f1 100644
--- a/base/testfiles/tlb0406.tlg
+++ b/base/testfiles/tlb0406.tlg
@@ -17,5 +17,5 @@ l. ...\DeclareMathSymbol{a}{7}{operators}{`\a}
 l. ...\DeclareMathSymbol{a}{7}{letters}{`\a}
 > 29025.
 <to be read again> 
-                   \tex_par:D 
+                   \scan_stop: 
 l. ...
diff --git a/base/testfiles/tlb0942.luatex.tlg b/base/testfiles/tlb0942.luatex.tlg
index b1e0a6be..119e2573 100644
--- a/base/testfiles/tlb0942.luatex.tlg
+++ b/base/testfiles/tlb0942.luatex.tlg
@@ -737,5 +737,5 @@ l. ...\showthe
             \mathcode`\z
 > 31457402.
 <to be read again> 
-\tex_par:D 
+\scan_stop: 
 l. ...
diff --git a/base/testfiles/tlb0942.tlg b/base/testfiles/tlb0942.tlg
index 3ffcf8a2..7f770986 100644
--- a/base/testfiles/tlb0942.tlg
+++ b/base/testfiles/tlb0942.tlg
@@ -737,5 +737,5 @@ l. ...\showthe
               \mathcode`\z
 > 29050.
 <to be read again> 
-                   \tex_par:D 
+                   \scan_stop: 
 l. ...
diff --git a/base/testfiles/tlb2558.luatex.tlg b/base/testfiles/tlb2558.luatex.tlg
index c9e33292..22b39a06 100644
--- a/base/testfiles/tlb2558.luatex.tlg
+++ b/base/testfiles/tlb2558.luatex.tlg
@@ -25,7 +25,7 @@ For xelatex or lualatex save the document in UTF-8 encoding
 and do not use inputenc, or use the [utf8] option.
 > 11.
 <to be read again> 
-\tex_par:D 
+\scan_stop: 
 l. ...
 ! Package inputenc Error: inputenc is not designed for xetex or luatex.
 (inputenc)                only UTF-8 supported.
diff --git a/base/testfiles/tlb2558.tlg b/base/testfiles/tlb2558.tlg
index 4a72c80b..ff25753e 100644
--- a/base/testfiles/tlb2558.tlg
+++ b/base/testfiles/tlb2558.tlg
@@ -20,7 +20,7 @@ File: latin1.def ....-..-.. v... Input encoding file
 )
 > 11.
 <to be read again> 
-                   \tex_par:D 
+                   \scan_stop: 
 l. ...
 > 12.
 l. ...\showthe\catcode`\@ 
diff --git a/base/testfiles/tlb2558.xetex.tlg b/base/testfiles/tlb2558.xetex.tlg
index c4c9554e..6aa88e2c 100644
--- a/base/testfiles/tlb2558.xetex.tlg
+++ b/base/testfiles/tlb2558.xetex.tlg
@@ -25,7 +25,7 @@ For xelatex or lualatex save the document in UTF-8 encoding
 and do not use inputenc, or use the [utf8] option.
 > 11.
 <to be read again> 
-                   \tex_par:D 
+                   \scan_stop: 
 l. ...
 ! Package inputenc Error: inputenc is not designed for xetex or luatex.
 (inputenc)                only UTF-8 supported.
diff --git a/required/firstaid/changes.txt b/required/firstaid/changes.txt
index 90845278..f84c9dbc 100644
--- a/required/firstaid/changes.txt
+++ b/required/firstaid/changes.txt
@@ -1,3 +1,9 @@
+2021-06-28  Frank Mittelbach  <Frank.Mittelbach at latex-project.org>
+
+	* latex2e-first-aid-for-external-files.dtx:
+	Add first aid for strange bogus para/end error due to listings's
+	redefinition of \vskip.
+
 2021-06-24  Frank Mittelbach  <Frank.Mittelbach at latex-project.org>
 
 	* latex2e-first-aid-for-external-files.dtx (subsection{\footref first aid}):
diff --git a/required/firstaid/latex2e-first-aid-for-external-files.dtx b/required/firstaid/latex2e-first-aid-for-external-files.dtx
index da630423..6b0efaf2 100644
--- a/required/firstaid/latex2e-first-aid-for-external-files.dtx
+++ b/required/firstaid/latex2e-first-aid-for-external-files.dtx
@@ -111,8 +111,8 @@
 %    \end{macrocode}
 %
 %    \begin{macrocode}
-\def\LaTeXFirstAidDate{2021/06/24}
-\def\LaTeXFirstAidVersion{v1.0n}
+\def\LaTeXFirstAidDate{2021/06/28}
+\def\LaTeXFirstAidVersion{v1.0o}
 %    \end{macrocode}
 %
 %    \begin{macrocode}
@@ -679,6 +679,36 @@
 \ExplSyntaxOff
 %    \end{macrocode}
 %
+%    The next fixes Github issue 605 (by inserting a \cs{scan_stop:}
+%    before doing the check for hmode.
+%    \begin{macrocode}
+\ExplSyntaxOn
+\cs_set_protected:Npn \para_end: {
+  \scan_stop:
+  \mode_if_horizontal:TF {
+    \mode_if_inner:F {
+         \tex_unskip:D
+         \hook_use:n{para/end}
+         \@kernel at after@para at end
+         \mode_if_horizontal:TF {
+           \if_int_compare:w 0 < \tex_lastnodetype:D
+             \tex_kern:D \c_zero_dim
+           \fi:
+           \tex_par:D
+           \hook_use:n{para/after}
+           \@kernel at after@para at after
+         }
+         { \msg_error:nnnn { hooks }{ para-mode }{end}{horizontal} }
+    }
+  }
+  \tex_par:D
+}
+\cs_set_eq:NN \par     \para_end:
+\cs_set_eq:NN \@@par   \para_end:
+\cs_set_eq:NN \endgraf \para_end:
+\ExplSyntaxOff
+%    \end{macrocode}
+%
 %    \begin{macrocode}
 %</kernel>
 %    \end{macrocode}





More information about the latex3-commits mailing list.