texlive[61804] Build/source/texk/web2c: ptex: Fix for \chardef 256

commits+hironobu at tug.org commits+hironobu at tug.org
Sun Jan 30 02:51:23 CET 2022


Revision: 61804
          http://tug.org/svn/texlive?view=revision&revision=61804
Author:   hironobu
Date:     2022-01-30 02:51:22 +0100 (Sun, 30 Jan 2022)
Log Message:
-----------
ptex: Fix for \chardef 256 and \mathcode 128--255

Modified Paths:
--------------
    trunk/Build/source/texk/web2c/ptexdir/ChangeLog
    trunk/Build/source/texk/web2c/ptexdir/ptex-base.ch
    trunk/Build/source/texk/web2c/uptexdir/ChangeLog
    trunk/Build/source/texk/web2c/uptexdir/uptex-m.ch

Modified: trunk/Build/source/texk/web2c/ptexdir/ChangeLog
===================================================================
--- trunk/Build/source/texk/web2c/ptexdir/ChangeLog	2022-01-30 00:49:15 UTC (rev 61803)
+++ trunk/Build/source/texk/web2c/ptexdir/ChangeLog	2022-01-30 01:51:22 UTC (rev 61804)
@@ -1,3 +1,9 @@
+2022-01-29  Hironobu Yamashita  <h.y.acetaminophen at gmail.com>
+
+	* ptex-base.ch: Fix \chardef code 256 in math.
+	  Fix \mathcode for 128--255 not working.
+	  https://github.com/texjporg/tex-jp-build/issues/129
+
 2022-01-27  Hironori Kitagawa  <h_kitagawa2001 at yahoo.co.jp>
 
 	* ptex-base.ch: Fix a mistake and avoid compiler warnings.
@@ -12,6 +18,7 @@
 	* ptex.defines: Add multistrlen{short,filename}, fromBUFFshort.
 	* ptex_version.h: Version p4.0.0.
 	* tests/filename_test.sh, tests/printkanji.tex: Added.
+	  https://github.com/texjporg/tex-jp-build/issues/81
 
 2022-01-10  Karl Berry  <karl at freefriends.org>
 

Modified: trunk/Build/source/texk/web2c/ptexdir/ptex-base.ch
===================================================================
--- trunk/Build/source/texk/web2c/ptexdir/ptex-base.ch	2022-01-30 00:49:15 UTC (rev 61803)
+++ trunk/Build/source/texk/web2c/ptexdir/ptex-base.ch	2022-01-30 01:51:22 UTC (rev 61804)
@@ -6060,7 +6060,7 @@
 restart: @<Get the next non-blank non-relax...@>;
 reswitch:case cur_cmd of
 letter,other_char,char_given:
-  if (is_char_ascii(cur_chr) or (cur_chr=256)) then begin
+  if is_char_ascii(cur_chr) then begin
     c:=ho(math_code(cur_chr));
     if c=@'100000 then
       begin @<Treat |cur_chr| as an active character@>;
@@ -6111,8 +6111,7 @@
 @y
 mmode+letter,mmode+other_char,mmode+char_given:
   if is_char_ascii(cur_chr) then
-    if cur_chr<128 then set_math_char(ho(math_code(cur_chr)))
-    else set_math_char(cur_chr)
+    set_math_char(ho(math_code(cur_chr)))
   else set_math_kchar(cur_chr);
 mmode+kanji,mmode+kana,mmode+other_kchar: begin
     cx:=cur_chr; set_math_kchar(KANJI(cx));
@@ -6119,8 +6118,7 @@
   end;
 mmode+char_num: begin scan_char_num; cur_chr:=cur_val;
   if is_char_ascii(cur_chr) then
-    if cur_chr<128 then set_math_char(ho(math_code(cur_chr)))
-    else set_math_char(cur_chr)
+    set_math_char(ho(math_code(cur_chr)))
   else set_math_kchar(cur_chr);
   end;
 @z

Modified: trunk/Build/source/texk/web2c/uptexdir/ChangeLog
===================================================================
--- trunk/Build/source/texk/web2c/uptexdir/ChangeLog	2022-01-30 00:49:15 UTC (rev 61803)
+++ trunk/Build/source/texk/web2c/uptexdir/ChangeLog	2022-01-30 01:51:22 UTC (rev 61804)
@@ -1,3 +1,7 @@
+2022-01-29  Hironobu Yamashita  <h.y.acetaminophen at gmail.com>
+
+	* uptex-m.ch: Adapt to ptex-base.ch fixes.
+
 2022-01-23  TANAKA Takuji  <ttk at t-lab.opal.ne.jp>
 
 	* uptex-m.ch, upbibtex.ch, updvitype.ch, uppltotf.ch, uptftopl.ch,

Modified: trunk/Build/source/texk/web2c/uptexdir/uptex-m.ch
===================================================================
--- trunk/Build/source/texk/web2c/uptexdir/uptex-m.ch	2022-01-30 00:49:15 UTC (rev 61803)
+++ trunk/Build/source/texk/web2c/uptexdir/uptex-m.ch	2022-01-30 01:51:22 UTC (rev 61804)
@@ -955,10 +955,10 @@
 
 @x
 letter,other_char,char_given:
-  if (is_char_ascii(cur_chr) or (cur_chr=256)) then begin
+  if is_char_ascii(cur_chr) then begin
 @y
 letter,other_char,char_given:
-  if (cur_chr>=0)and(cur_chr<=256) then begin
+  if check_echar_range(cur_chr) then begin
 @z
 
 @x
@@ -982,8 +982,7 @@
 @x
 mmode+letter,mmode+other_char,mmode+char_given:
   if is_char_ascii(cur_chr) then
-    if cur_chr<128 then set_math_char(ho(math_code(cur_chr)))
-    else set_math_char(cur_chr)
+    set_math_char(ho(math_code(cur_chr)))
   else set_math_kchar(cur_chr);
 mmode+kanji,mmode+kana,mmode+other_kchar: begin
     cx:=cur_chr; set_math_kchar(KANJI(cx));
@@ -990,15 +989,13 @@
   end;
 mmode+char_num: begin scan_char_num; cur_chr:=cur_val;
   if is_char_ascii(cur_chr) then
-    if cur_chr<128 then set_math_char(ho(math_code(cur_chr)))
-    else set_math_char(cur_chr)
+    set_math_char(ho(math_code(cur_chr)))
   else set_math_kchar(cur_chr);
   end;
 @y
 mmode+letter,mmode+other_char,mmode+char_given:
   if check_echar_range(cur_chr) then
-    if cur_chr<128 then set_math_char(ho(math_code(cur_chr)))
-    else set_math_char(cur_chr)
+    set_math_char(ho(math_code(cur_chr)))
   else set_math_kchar(cur_chr);
 mmode+kanji,mmode+kana,mmode+other_kchar,mmode+hangul: begin
     cx:=cur_chr; set_math_kchar(KANJI(cx));
@@ -1005,8 +1002,7 @@
   end;
 mmode+char_num: begin scan_char_num; cur_chr:=cur_val;
   if check_echar_range(cur_chr) then
-    if cur_chr<128 then set_math_char(ho(math_code(cur_chr)))
-    else set_math_char(cur_chr)
+    set_math_char(ho(math_code(cur_chr)))
   else set_math_kchar(cur_chr);
   end;
 mmode+kchar_given:



More information about the tex-live-commits mailing list.