[latex3-commits] [git/LaTeX3-latex3-latex3] master: Correct endlinechar in \c_code_cctab and add test catching that (e0ff2d337)

Joseph Wright joseph.wright at morningstar2.co.uk
Thu Jul 16 12:13:16 CEST 2020


Repository : https://github.com/latex3/latex3
On branch  : master
Link       : https://github.com/latex3/latex3/commit/e0ff2d33791e65c946869d2c44d2ad68986a18a7

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

commit e0ff2d33791e65c946869d2c44d2ad68986a18a7
Author: Bruno Le Floch <bruno at le-floch.fr>
Date:   Fri Jul 10 22:32:01 2020 +0200

    Correct endlinechar in \c_code_cctab and add test catching that


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

e0ff2d33791e65c946869d2c44d2ad68986a18a7
 l3kernel/l3cctab.dtx              |  4 ++--
 l3kernel/testfiles/m3cctab001.lvt | 11 +++++++----
 2 files changed, 9 insertions(+), 6 deletions(-)

diff --git a/l3kernel/l3cctab.dtx b/l3kernel/l3cctab.dtx
index 810223dfb..56b451fd5 100644
--- a/l3kernel/l3cctab.dtx
+++ b/l3kernel/l3cctab.dtx
@@ -782,13 +782,13 @@
   {
     \@@_new:N \c_code_cctab
     \group_begin:
-      \int_set:Nn \tex_endlinechar:D { 13 }
+      \int_set:Nn \tex_endlinechar:D { 32 }
       \char_set_catcode_ignore:n           { 9 }   % tab
       \char_set_catcode_ignore:n           { 32 }  % space
       \char_set_catcode_other:n            { 34 }  % double quote
       \char_set_catcode_alignment:n        { 38 }  % ampersand
       \char_set_catcode_letter:n           { 58 }  % colon
-      \char_set_catcode_other:n            { 64 }  % ampersand
+      \char_set_catcode_other:n            { 64 }  % at sign
       \char_set_catcode_math_superscript:n { 94 }  % circumflex
       \char_set_catcode_letter:n           { 95 }  % underscore
       \char_set_catcode_other:n            { 124 } % pipe
diff --git a/l3kernel/testfiles/m3cctab001.lvt b/l3kernel/testfiles/m3cctab001.lvt
index 561099d20..86a02b15b 100644
--- a/l3kernel/testfiles/m3cctab001.lvt
+++ b/l3kernel/testfiles/m3cctab001.lvt
@@ -16,8 +16,8 @@
 \ExplSyntaxOn
 
 \OMIT
-\intarray_new:Nn \TESTintarrayA { 256 }
-\intarray_new:Nn \TESTintarrayB { 256 }
+\intarray_new:Nn \TESTintarrayA { 257 }
+\intarray_new:Nn \TESTintarrayB { 257 }
 \cs_new:Npn \SAVECATCODES #1
   {
     \int_step_inline:nnn { 1 } { 256 }
@@ -25,12 +25,13 @@
         \intarray_gset:Nnn #1 {##1}
           { \char_value_catcode:n {##1-1} }
       }
+    \intarray_gset:Nnn #1 { 257 } { \tex_endlinechar:D }
   }
 \tl_new:N \l__test_tl
 \prg_new_protected_conditional:Npnn \intarray_if_eq:NN #1 #2 { TF }
   {
     \tl_clear:N \l__test_tl
-    \int_step_inline:nnn { 1 } { 256 }
+    \int_step_inline:nnn { 1 } { 257 }
       {
         \int_compare:nNnF
           { \intarray_item:Nn #1 {##1} }
@@ -39,7 +40,9 @@
           {
             \tl_put_right:Nx \l__test_tl
               {
-                '\char_generate:nn { ##1 - 1 } { 12 }'
+                \int_compare:nNnTF { ##1 } = { 257 }
+                  { endlinechar ~ }
+                  { '\char_generate:nn { ##1 - 1 } { 12 }' ~ }
                 ( \intarray_item:Nn #1 {##1} != \intarray_item:Nn #2 {##1}) ~
               }
           }





More information about the latex3-commits mailing list.