[latex3-commits] [git/LaTeX3-latex3-latex2e] gh367: and a further one for escaping ^^M chars into the OR (f04944c4)

Frank Mittelbach frank.mittelbach at latex-project.org
Wed Jan 26 15:31:34 CET 2022


Repository : https://github.com/latex3/latex2e
On branch  : gh367
Link       : https://github.com/latex3/latex2e/commit/f04944c4ef08fc37ed5af597d7a01211ce3cdb9a

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

commit f04944c4ef08fc37ed5af597d7a01211ce3cdb9a
Author: Frank Mittelbach <frank.mittelbach at latex-project.org>
Date:   Wed Jan 26 15:31:34 2022 +0100

    and a further one for escaping ^^M chars into the OR


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

f04944c4ef08fc37ed5af597d7a01211ce3cdb9a
 base/ltplain.dtx | 8 +++++++-
 1 file changed, 7 insertions(+), 1 deletion(-)

diff --git a/base/ltplain.dtx b/base/ltplain.dtx
index 126483f1..1a3c02d0 100644
--- a/base/ltplain.dtx
+++ b/base/ltplain.dtx
@@ -1253,8 +1253,14 @@
 %    For the default definition we have to use \cs{def} not \cs{let}
 %    because the meaning of \cs{par} can change and we want to use the
 %    one that is current when \cs{obeylines} act.
+%
+%    There is a small subtlety here: in an \cs{edef} the active |^^M| stayed
+%    put (because it was equal to to the primitive \cs{par}), now
+%    \cs{obeyedline} expands and you get what it  contains, i.e., in that
+%    case \cs{par}, into the \cs{edef} or \cs{mark} unless we use
+%    \cs{protected} on it.
 %    \begin{macrocode}
-\gdef\obeyedline{\par}
+\protected\gdef\obeyedline{\par}
 %    \end{macrocode}
 % \end{macro}
 %





More information about the latex3-commits mailing list.