summaryrefslogtreecommitdiff
path: root/Build/source/texk/web2c/ptexdir/ptex-base.ch
diff options
context:
space:
mode:
authorHironobu Yamashita <h.y.acetaminophen@gmail.com>2019-07-12 16:07:27 +0000
committerHironobu Yamashita <h.y.acetaminophen@gmail.com>2019-07-12 16:07:27 +0000
commit3e3ef209c676a34275271415b131a95ad024a0c2 (patch)
treefcce8ecc851bc3ad095731670268eebbfdebe388 /Build/source/texk/web2c/ptexdir/ptex-base.ch
parente79133fcc651c459e8ce7bd269b758098cbe40d6 (diff)
ptex: strict '! Improper alphabetic or KANJI constant.' error
git-svn-id: svn://tug.org/texlive/trunk@51623 c570f23f-e606-0410-a88d-b1316a301751
Diffstat (limited to 'Build/source/texk/web2c/ptexdir/ptex-base.ch')
-rw-r--r--Build/source/texk/web2c/ptexdir/ptex-base.ch12
1 files changed, 10 insertions, 2 deletions
diff --git a/Build/source/texk/web2c/ptexdir/ptex-base.ch b/Build/source/texk/web2c/ptexdir/ptex-base.ch
index 891861b331e..5b4ff551aff 100644
--- a/Build/source/texk/web2c/ptexdir/ptex-base.ch
+++ b/Build/source/texk/web2c/ptexdir/ptex-base.ch
@@ -2275,8 +2275,16 @@ if cur_tok<cs_token_flag then
end
else if cur_tok<cs_token_flag+single_base then
cur_val:=cur_tok-cs_token_flag-active_base
-else cur_val:=cur_tok-cs_token_flag-single_base;
-if (cur_val>255)and((cur_cmd<kanji)or(cur_cmd>max_char_code)) then
+else
+ { the token is a CS;
+ * if |kanji|<=|cur_cmd|<=|max_char_code|, then CS is let-equal to |wchar_token|
+ * if |max_char_code|<|cur_cmd|, then CS is a multibyte CS
+ => both case should raise "Improper ..." error
+ * otherwise it should be a single-character CS with |cur_val|<=255 }
+ begin if not (cur_cmd<kanji) then cur_cmd:=invalid_char;
+ cur_val:=cur_tok-cs_token_flag-single_base;
+ end;
+if (cur_val>255)and(cur_cmd<kanji) then
begin print_err("Improper alphabetic or KANJI constant");
@.Improper alphabetic constant@>
help2("A one-character control sequence belongs after a ` mark.")@/