[latex3-commits] [l3svn] branch master updated: Put the input encoding code in the right place!

noreply at latex-project.org noreply at latex-project.org
Fri Nov 13 13:10:40 CET 2015


This is an automated email from the git hooks/post-receive script.

joseph pushed a commit to branch master
in repository l3svn.

The following commit(s) were added to refs/heads/master by this push:
       new  5db7849   Put the input encoding code in the right place!
5db7849 is described below

commit 5db7849227f08f92c6cf9e7bbbc02ac49e5d82e3
Author: Joseph Wright <joseph.wright at morningstar2.co.uk>
Date:   Fri Nov 13 12:09:55 2015 +0000

    Put the input encoding code in the right place!
    
    As well as moving to before the \dump line, this also
    corrects various minor typos in the previous checkin.
---
 l3kernel/l3final.dtx |  154 +++++++++++++++++++++++++-------------------------
 1 file changed, 77 insertions(+), 77 deletions(-)

diff --git a/l3kernel/l3final.dtx b/l3kernel/l3final.dtx
index dc0bb87..2f7d577 100644
--- a/l3kernel/l3final.dtx
+++ b/l3kernel/l3final.dtx
@@ -239,71 +239,6 @@
 \char_set_lccode:nn { `\- } { `\- }
 %    \end{macrocode}
 %
-% \subsection{Temporary hacks}
-%
-% \begin{macro}{\T1/lmr/m/n/10}
-%   For \emph{testing only} provide some kind of output: for that we
-%   need a font. At present, select Latin Modern Roman at 10\,pt:
-%   entirely arbitrary but at least usable.
-%    \begin{macrocode}
-\tex_everypar:D \exp_after:wN
-  {
-    \exp_after:wN \tex_font:D \cs:w T1/lmr/m/n/10 \cs_end:
-      = ec-lmr10 \scan_stop:
-    \use:c { T1/lmr/m/n/10 }
-  }
-%    \end{macrocode}
-% \end{macro}
-%
-%  Produce PDF output if possible (easier testing) and set some kind of
-%  horizontal width: the one here is the \LaTeXe{} default. A parfill is
-%  also useful so we get some kind of sensible paragraphs.
-%    \begin{macrocode}
-\dim_set:Nn \tex_hsize:D { 345pt }
-\skip_set:Nn \tex_parfillskip:D { 0pt plus 1fil }
-\cs_if_exist:NT \pdftex_pdfoutput:D
-  { \int_set:Nn \pdftex_pdfoutput:D { 1 } }
-%    \end{macrocode}
-%
-% \begin{macro}{\stop}
-%   A way out of the run without needing to switch to the code environment.
-%    \begin{macrocode}
-\cs_set_eq:NN \stop \tex_end:D
-%    \end{macrocode}
-% \end{macro}
-%
-% \subsection{Final tasks}
-%
-% \begin{macro}{\par}
-%   \TeX{} has a nasty habit of inserting a command with the name \cs{par}
-%   so we had better make sure that \cs{par} has a definition.
-%    \begin{macrocode}
-\cs_set_eq:NN \par \tex_par:D
-%    \end{macrocode}
-% \end{macro}
-%
-% The very last job is to dump the format, taking care to first leave
-% the code environment and set the appropriate flag.
-%    \begin{macrocode}
-\use:n
-  {
-    \bool_set_false:N \l__kernel_expl_bool
-    \char_set_catcode_space:n  { 9 }   % tab
-    \char_set_catcode_space:n  { 32 }  % space
-    \char_set_catcode_active:n { 34 }  % double quote
-    \char_set_catcode_active:n { 36 }  % dollar
-    \char_set_catcode_active:n { 38 }  % ampersand
-    \char_set_catcode_other:n  { 58 }  % colon
-    \char_set_catcode_active:n { 94 }  % circumflex
-    \char_set_catcode_active:n { 95 }  % underscore
-    \char_set_catcode_other:n  { 124 } % pipe
-    \char_set_catcode_active:n { 126 } % tilde
-    \tex_endlinechar:D = 13 \scan_stop:
-    \tex_newlinechar:D = 10 \scan_stop:
-    \tex_dump:D
-  }
-%    \end{macrocode}
-%
 % \subsection{Input encoding}
 %
 % The letters |a|--|z| and |A|--|Z| will be correct directly from Ini\TeX{}
@@ -314,12 +249,12 @@
 % All the characters in the range $0$--$31$ \emph{except} tab (|^^I|), nl
 % (|^^J|), ff (|^^L|), cr (|^^M|), dotless-I (|^^Y|) and dotless-J (|^^Z|).
 %    \begin{macrocode}
-\int_step_inline:nn { 0 } { 1 } { `\^^H }
+\int_step_inline:nnnn { 0 } { 1 } { `\^^H }
   { \char_set_catcode_invalid:n {#1} }
 \char_set_catcode_invalid:n { `\^^K }
-\int_step_inline:nn { `\^^N } { 1 } { ^^W }
+\int_step_inline:nnnn { `\^^N } { 1 } { `\^^W }
   { \char_set_catcode_invalid:n {#1} }
-\int_step_inline:nn { 27 } { 1 } { 31 }
+\int_step_inline:nnnn { 27 } { 1 } { 31 }
   { \char_set_catcode_invalid:n {#1} }
 %    \end{macrocode}
 % The same is true for the top of the $7$-bit range.
@@ -350,7 +285,7 @@
 %    \end{macrocode}
 % The actual mappings: these are kept low-level for performance reasons.
 %    \begin{macrocode}
-    \cs_new_nopar:Npn { __char_active_C3:N } #1
+    \cs_new_nopar:cpn { __char_active_C3:N } #1
       {
         \if_meaning:w #1 ^^9f ^^ff \else: % ß - U+00DF - germandbls
         \if_meaning:w #1 ^^a0 ^^e0 \else: % à - U+00E0 - agrave
@@ -388,7 +323,7 @@
         \fi: \fi: \fi: \fi: \fi: \fi: \fi: \fi: \fi: \fi: \fi:
         \fi: \fi: \fi: \fi: \fi: \fi: \fi: \fi: \fi: \fi:
       }
-    \cs_new_nopar:Npn { __char_active_C4:N } #1
+    \cs_new_nopar:cpn { __char_active_C4:N } #1
       {
         \if_meaning:w #1 ^^83 ^^a0 \else: % ă - U+0103 - abreve
         \if_meaning:w #1 ^^85 ^^a1 \else: % ą - U+0105 - aogonek
@@ -404,9 +339,9 @@
         \if_meaning:w #1 ^^ba ^^a8 \else: % ĺ - U+013A - lacute
         \if_meaning:w #1 ^^be ^^a9 \else: % ľ - U+013E - lcaron
           \__msg_kernel_expandable_error:nn { kernel } { encoding-failure }
-        \fi: \fi: \fi: \fi: \fi: \fi: \fi: \fi: \fi: \fi: \fi: \fi: \fi
+        \fi: \fi: \fi: \fi: \fi: \fi: \fi: \fi: \fi: \fi: \fi: \fi: \fi:
       }
-    \cs_new_nopar:Npn { __char_active_C5:N } #1
+    \cs_new_nopar:cpn { __char_active_C5:N } #1
       {
         \if_meaning:w #1 ^^82 ^^aa \else: % ł - U+0142 - lslash
         \if_meaning:w #1 ^^84 ^^ab \else: % ń - U+0144 - nacute
@@ -429,7 +364,7 @@
         \fi: \fi: \fi: \fi: \fi: \fi: \fi: \fi: \fi:
         \fi: \fi: \fi: \fi: \fi: \fi: \fi: \fi:
       }
-    \cs_new_nopar:Npn { __char_active_C8:N } #1
+    \cs_new_nopar:cpn { __char_active_C8:N } #1
       {
         \if_meaning:w #1 ^^99 ^^b3 \else: % ș - U+0219 - scommaaccent
         \if_meaning:w #1 ^^9b ^^b5 \else: % ț - U+021B - tcommaaccent
@@ -440,14 +375,14 @@
 %    \end{macrocode}
 % Install and record the active characters.
 %    \begin{macrocode}
-    \clist_step_inline:nn { C3 , C4 , C5 , C8 }
+    \clist_map_inline:nn { C3 , C4 , C5 , C8 }
       {
         \char_set_catcode_active:n { "#1 }
-        \cs_set_active_eq:nc { "#1 } { __char_active_ #1 :N }
+        \char_set_active_eq:nc { "#1 } { __char_active_ #1 :N }
         \seq_put_right:Nx \l_char_special_seq
-          { \exp_not:c { \char_generate:n { "#1 } } }
+          { \exp_not:c { \char_generate:nn { "#1 } { 12 } } }
         \seq_put_right:Nx \l_char_active_seq
-          { \exp_not:c { \char_generate:n { "#1 } } }
+          { \exp_not:c { \char_generate:nn { "#1 } { 12 } } }
       }
     \__msg_kernel_new:nnn { kernel } { encoding-failure }
       { Unknown~UTF-8~char }
@@ -467,6 +402,71 @@
   }
 %    \end{macrocode}
 %
+% \subsection{Temporary hacks}
+%
+% \begin{macro}{\T1/lmr/m/n/10}
+%   For \emph{testing only} provide some kind of output: for that we
+%   need a font. At present, select Latin Modern Roman at 10\,pt:
+%   entirely arbitrary but at least usable.
+%    \begin{macrocode}
+\tex_everypar:D \exp_after:wN
+  {
+    \exp_after:wN \tex_font:D \cs:w T1/lmr/m/n/10 \cs_end:
+      = ec-lmr10 \scan_stop:
+    \use:c { T1/lmr/m/n/10 }
+  }
+%    \end{macrocode}
+% \end{macro}
+%
+%  Produce PDF output if possible (easier testing) and set some kind of
+%  horizontal width: the one here is the \LaTeXe{} default. A parfill is
+%  also useful so we get some kind of sensible paragraphs.
+%    \begin{macrocode}
+\dim_set:Nn \tex_hsize:D { 345pt }
+\skip_set:Nn \tex_parfillskip:D { 0pt plus 1fil }
+\cs_if_exist:NT \pdftex_pdfoutput:D
+  { \int_set:Nn \pdftex_pdfoutput:D { 1 } }
+%    \end{macrocode}
+%
+% \begin{macro}{\stop}
+%   A way out of the run without needing to switch to the code environment.
+%    \begin{macrocode}
+\cs_set_eq:NN \stop \tex_end:D
+%    \end{macrocode}
+% \end{macro}
+%
+% \subsection{Final tasks}
+%
+% \begin{macro}{\par}
+%   \TeX{} has a nasty habit of inserting a command with the name \cs{par}
+%   so we had better make sure that \cs{par} has a definition.
+%    \begin{macrocode}
+\cs_set_eq:NN \par \tex_par:D
+%    \end{macrocode}
+% \end{macro}
+%
+% The very last job is to dump the format, taking care to first leave
+% the code environment and set the appropriate flag.
+%    \begin{macrocode}
+\use:n
+  {
+    \bool_set_false:N \l__kernel_expl_bool
+    \char_set_catcode_space:n  { 9 }   % tab
+    \char_set_catcode_space:n  { 32 }  % space
+    \char_set_catcode_active:n { 34 }  % double quote
+    \char_set_catcode_active:n { 36 }  % dollar
+    \char_set_catcode_active:n { 38 }  % ampersand
+    \char_set_catcode_other:n  { 58 }  % colon
+    \char_set_catcode_active:n { 94 }  % circumflex
+    \char_set_catcode_active:n { 95 }  % underscore
+    \char_set_catcode_other:n  { 124 } % pipe
+    \char_set_catcode_active:n { 126 } % tilde
+    \tex_endlinechar:D = 13 \scan_stop:
+    \tex_newlinechar:D = 10 \scan_stop:
+    \tex_dump:D
+  }
+%    \end{macrocode}
+%
 %    \begin{macrocode}
 %</initex>
 %    \end{macrocode}

-- 
To stop receiving notification emails like this one, please contact
the administrator of this repository.


More information about the latex3-commits mailing list