[latex3-commits] [latex3/latex2e] develop: Add a code comment (a4df9c4b)
github at latex-project.org
github at latex-project.org
Fri Oct 27 11:12:07 CEST 2023
Repository : https://github.com/latex3/latex2e
On branch : develop
Link : https://github.com/latex3/latex2e/commit/a4df9c4bd31177e10bbc3ca4516b6f32442413d2
>---------------------------------------------------------------
commit a4df9c4bd31177e10bbc3ca4516b6f32442413d2
Author: Joseph Wright <joseph.wright at morningstar2.co.uk>
Date: Thu Oct 26 17:52:21 2023 +0100
Add a code comment
>---------------------------------------------------------------
a4df9c4bd31177e10bbc3ca4516b6f32442413d2
base/ltspace.dtx | 6 +++++-
1 file changed, 5 insertions(+), 1 deletion(-)
diff --git a/base/ltspace.dtx b/base/ltspace.dtx
index 0c08ab52..59b7744b 100644
--- a/base/ltspace.dtx
+++ b/base/ltspace.dtx
@@ -1214,13 +1214,17 @@
% We need to keep \cs{@xobeysp} as it is widely used; so here it is
% let to the non-robust command \cs{nobreakspace }.
%
+% The fragile version of |~| needs a brace group after \cs{nobreakspace}
+% to prevent loss of spaces if it occurs in an expansion context. That's
+% not an issue with the updated \cs{protected} definition, so we keep the
+% code shorter and avoid that.
% \begin{macrocode}
\DeclareRobustCommand{\nobreakspace}{%
\leavevmode\nobreak\ }
\catcode `\~=13
%</2ekernel>
%<latexrelease>\IncludeInRelease{2023/11/01}%
-%<latexrelease> {[tilde]}{Protected tilde}%
+%<latexrelease> {\tilde}{Protected tilde}%
%<*2ekernel|latexrelease>
\protected\edef~{%
\noexpand\ifincsname\noexpand\expandafter\string~%
More information about the latex3-commits
mailing list.