Skip to content

Commit

Permalink
{,e}uptex: Remove kcatcode latin_ucs (14)
Browse files Browse the repository at this point in the history
git-svn-id: svn://tug.org/texlive/trunk/Build/source@72410 c570f23f-e606-0410-a88d-b1316a301751
  • Loading branch information
t-tk committed Sep 30, 2024
1 parent 6cc1aa2 commit 02ecb35
Show file tree
Hide file tree
Showing 4 changed files with 12 additions and 16 deletions.
5 changes: 5 additions & 0 deletions texk/web2c/euptexdir/ChangeLog
Original file line number Diff line number Diff line change
@@ -1,3 +1,8 @@
2024-09-30 TANAKA Takuji <[email protected]>

* eptex.ech: kcatcode (latin_ucs(14)) is removed
since it will be supported in upTeX-2.00.

2024-09-28 TANAKA Takuji <[email protected]>

* euptex-{ctrlsym,kinsoku,prntknj}.test:
Expand Down
1 change: 0 additions & 1 deletion texk/web2c/euptexdir/eptex.ech
Original file line number Diff line number Diff line change
Expand Up @@ -729,7 +729,6 @@ if j=1 then
if (multistrlen(ustringcast(buffer), limit+1,loc)>1)and
check_kcat_code(cur_tok,cur_chr) then
begin if (cur_tok=not_cjk) then cur_tok:=other_kchar;
if (cur_tok=latin_ucs) then cur_tok:=other_token;
cur_tok:=cur_chr+cur_tok*max_cjk_val;
loc:=loc+multistrlen(ustringcast(buffer), limit+1,loc);
end
Expand Down
5 changes: 5 additions & 0 deletions texk/web2c/uptexdir/ChangeLog
Original file line number Diff line number Diff line change
@@ -1,3 +1,8 @@
2024-09-30 TANAKA Takuji <[email protected]>

* uptex-m.ch: kcatcode (latin_ucs(14)) is removed
since it will be supported in upTeX-2.00.

2024-09-28 TANAKA Takuji <[email protected]>

* uptex-m.ch, upbibtex.ch, kanji.c:
Expand Down
17 changes: 2 additions & 15 deletions texk/web2c/uptexdir/uptex-m.ch
Original file line number Diff line number Diff line change
Expand Up @@ -176,7 +176,6 @@ else if (kcode_pos=1)or((kcode_pos>=@'11)and(kcode_pos<=@'12))
@d other_kchar=18 {kanji codes}
@d max_char_code=18 {largest catcode for individual characters}
@y
@d latin_ucs=14 {is not cjk characters in ucs code}
@d not_cjk=15 {is not cjk characters}
@d kanji=16 {kanji}
@d kana=17 {hiragana, katakana, alphabet}
Expand Down Expand Up @@ -428,7 +427,6 @@ if ((kcp mod @'10)>0)and(nrestmultichr(kcp)>0) then p:=p-(kcp mod @'10);
cur_chr:=fromBUFF(ustringcast(buffer), limit+1, loc);
cur_cmd:=kcat_code(kcatcodekey(cur_chr));
if (multistrlen(ustringcast(buffer), limit+1, loc)>1) and check_kcat_code(cur_cmd,cur_chr) then begin
if (cur_cmd=latin_ucs) then cur_cmd:=cat_code(cur_chr);
if (cur_cmd=not_cjk) then cur_cmd:=other_kchar;
for l:=loc to loc-1+multistrlen(ustringcast(buffer), limit+1, loc) do
buffer2[l]:=1;
Expand Down Expand Up @@ -479,7 +477,6 @@ else begin k:=loc;
cur_chr:=fromBUFF(ustringcast(buffer), limit+1, k);
cat:=kcat_code(kcatcodekey(cur_chr));
if (multistrlen(ustringcast(buffer), limit+1, k)>1) and check_kcat_code(cat,cur_chr) then begin
if (cat=latin_ucs) then cat:=cat_code(cur_chr);
if (cat=not_cjk) then cat:=other_kchar;
for l:=k to k-1+multistrlen(ustringcast(buffer), limit+1, k) do
buffer2[l]:=1;
Expand Down Expand Up @@ -522,7 +519,6 @@ begin repeat
cur_chr:=fromBUFF(ustringcast(buffer), limit+1, k);
cat:=kcat_code(kcatcodekey(cur_chr));
if (multistrlen(ustringcast(buffer), limit+1, k)>1) and check_kcat_code(cat,cur_chr) then begin
if (cat=latin_ucs) then cat:=cat_code(cur_chr);
if (cat=not_cjk) then cat:=other_kchar;
for l:=k to k-1+multistrlen(ustringcast(buffer), limit+1, k) do
buffer2[l]:=1;
Expand Down Expand Up @@ -577,8 +573,6 @@ if cat=other_kchar then k:=k-multilenbuffchar(cur_chr)+1; {now |k| points to fir
cur_tok:=(kanji_ivs*max_cjk_val)+cur_chr
else
cur_tok:=(cur_cmd*max_cjk_val)+cur_chr
else if (cur_cmd=latin_ucs) then
cur_tok:=(cat_code(cur_chr)*max_cjk_val)+cur_chr
else cur_tok:=(cur_cmd*max_char_val)+cur_chr
@z
Expand Down Expand Up @@ -612,8 +606,6 @@ if cat=other_kchar then k:=k-multilenbuffchar(cur_chr)+1; {now |k| points to fir
cur_tok:=(kanji_ivs*max_cjk_val)+cur_chr
else
cur_tok:=(cur_cmd*max_cjk_val)+cur_chr
else if (cur_cmd=latin_ucs) then
cur_tok:=(cat_code(cur_chr)*max_cjk_val)+cur_chr
else cur_tok:=(cur_cmd*max_char_val)+cur_chr
@z
Expand All @@ -627,8 +619,6 @@ if cat=other_kchar then k:=k-multilenbuffchar(cur_chr)+1; {now |k| points to fir
cur_tok:=(kanji_ivs*max_cjk_val)+cur_chr
else
cur_tok:=(cur_cmd*max_cjk_val)+cur_chr
else if (cur_cmd=latin_ucs) then
cur_tok:=(cat_code(cur_chr)*max_cjk_val)+cur_chr
else cur_tok:=(cur_cmd*max_char_val)+cur_chr
@z
Expand Down Expand Up @@ -698,7 +688,6 @@ while k<pool_ptr do
begin t:=so(str_pool[k]);
if t>=@"180 then { there is no |wchar_token| whose code is 0--127. }
begin t:=fromBUFFshort(str_pool, pool_ptr, k); cc:=kcat_code(kcatcodekey(t));
if (cc=latin_ucs) then cc:=other_char;
if (cc=not_cjk) then cc:=other_kchar;
if (cc=kanji)and(t>=max_cjk_val) then cc:=kanji_ivs;
t:=t+cc*max_cjk_val;
Expand Down Expand Up @@ -1188,7 +1177,7 @@ kchar_given: begin print_esc("kchar"); print_hex(chr_code);
if cur_chr=kcat_code_base then m:=kanji else m:=0
@y
@ @<Let |m| be the minimal...@>=
if cur_chr=kcat_code_base then m:=latin_ucs else m:=0
if cur_chr=kcat_code_base then m:=not_cjk else m:=0
@z
@x
Expand Down Expand Up @@ -1332,8 +1321,6 @@ begin if is_char_node(link(p)) then
info(main_p):=KANJI(cur_chr)+cur_cmd*max_cjk_val
else if cur_cmd=not_cjk then
info(main_p):=KANJI(cur_chr)+other_kchar*max_cjk_val
else if cur_cmd=latin_ucs then
info(main_p):=KANJI(cur_chr)+cat_code(cur_chr)*max_cjk_val
else { Does this case occur? }
info(main_p):=KANJI(cur_chr)+kcat_code(kcatcodekey(KANJI(cur_chr)))*max_cjk_val;
@z
Expand Down Expand Up @@ -1428,7 +1415,7 @@ end;

function check_kcat_code(@!ct:integer;@!cx:integer):integer;
begin
if (((ct>=kanji)or((ct=latin_ucs)and(cx<max_ucs_val)))and(enable_cjk_token=0))or(enable_cjk_token=2)then
if ((ct>=kanji)and(enable_cjk_token=0))or(enable_cjk_token=2)then
check_kcat_code:=1
else check_kcat_code:=0;
end;
Expand Down

0 comments on commit 02ecb35

Please sign in to comment.