[latex3-commits] [latex3/latex3] general-category: Gen. cat. for unassigned codepoints is Cn (a7d12b6cc)

github at latex-project.org github at latex-project.org
Tue Jun 20 07:00:07 CEST 2023


Repository : https://github.com/latex3/latex3
On branch  : general-category
Link       : https://github.com/latex3/latex3/commit/a7d12b6cc7252c3f5b8ea20fb67d9695dd3106bf

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

commit a7d12b6cc7252c3f5b8ea20fb67d9695dd3106bf
Author: Joseph Wright <joseph.wright at morningstar2.co.uk>
Date:   Tue Jun 20 06:00:07 2023 +0100

    Gen. cat. for unassigned codepoints is Cn


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

a7d12b6cc7252c3f5b8ea20fb67d9695dd3106bf
 l3kernel/l3unicode.dtx | 19 +++++++++++--------
 1 file changed, 11 insertions(+), 8 deletions(-)

diff --git a/l3kernel/l3unicode.dtx b/l3kernel/l3unicode.dtx
index a78e2cb29..42ef99cf0 100644
--- a/l3kernel/l3unicode.dtx
+++ b/l3kernel/l3unicode.dtx
@@ -622,19 +622,22 @@
     }
 %    \end{macrocode}
 %  Distinguish between a range and a gap, and pass on the appropriate value(s).
+%  The general category for unassigned characters is \texttt{Cn}, so we
+%  find the correct value once and then use that.
 %    \begin{macrocode}
-  \cs_set_protected:Npn \@@_data_auxv:nnnnw #1#2#3#4#5 Last> #6 \q_stop
+  \cs_set_protected:Npx \@@_data_auxv:nnnnw #1#2#3#4#5 Last> #6 \q_stop
     {
-       \tl_if_blank:nTF {#6}
+       \exp_not:N \tl_if_blank:nTF {#6}
          {
-           \@@_range:nnn {#1} { category } { 0 }
-           \@@_range:nnn {#1} { uppercase } { 0 }
-           \@@_range:nnn {#1} { lowercase } { 0 }
+           \exp_not:N \@@_range:nnn {#1} { category }
+             \exp_not:V \l_@@_category_Cn_tl
+           \exp_not:N \@@_range:nnn {#1} { uppercase } { 0 }
+           \exp_not:N \@@_range:nnn {#1} { lowercase } { 0 }
          }
          {
-           \@@_range:nnn {#1} { category } {#2}
-           \@@_range:nnn {#1} { uppercase } {#3}
-           \@@_range:nnn {#1} { lowercase } {#4}
+           \exp_not:N \@@_range:nnn {#1} { category } {#2}
+           \exp_not:N \@@_range:nnn {#1} { uppercase } {#3}
+           \exp_not:N \@@_range:nnn {#1} { lowercase } {#4}
          }      
     }
 %    \end{macrocode}





More information about the latex3-commits mailing list.