unofficial mirror of bug-gnu-emacs@gnu.org 
 help / color / mirror / code / Atom feed
From: Yasuhiro Kimura <yasu@utahime.org>
To: 69536@debbugs.gnu.org
Subject: bug#69536: 30.0.50; Runtime error happens with Tamago input method after recent change with obarry
Date: Mon, 04 Mar 2024 17:41:45 +0900 (JST)	[thread overview]
Message-ID: <20240304.174145.1968255587035225823.yasu@utahime.org> (raw)
In-Reply-To: <20240304.150431.794612605227281106.yasu@utahime.org>

There are following lines (line 1360-1484) in its.el (can download
from https://github.com/hrs-allbsd/tamago/blob/freebsd/its.el).

----------------------------------------------------------------------
(defconst its-full-half-table (make-vector 100 nil))
(defconst its-half-full-table (make-vector 100 nil))

(let ((table '((Japanese
		(?  . ?\ ) (?, . ?,)  (?. . ?.)  (?、 . ?,)  (?。 . ?.)
		(?: . ?:)  (?; . ?\;) (?? . ??)  (?! . ?!)
		(?´ . ?')  (?` . ?`)  (?^ . ?^)  (?_ . ?_)  (? ̄ . ?~)
		(?ー . ?-)  (?— . ?-)  (?‐ . ?-)
		(?/ . ?/)  (?\ . ?\\) (?〜 . ?~)  (?| . ?|)
		(?‘ . ?`)  (?’ . ?')  (?“ . ?\") (?” . ?\")
		(?( . ?\() (?) . ?\)) (?[ . ?\[)  (?] . ?\])
		(?{ . ?{)  (?} . ?})  (?〈 . ?<)  (?〉 . ?>)
		(?+ . ?+)  (?− . ?-)  (?= . ?=)  (?< . ?<)  (?> . ?>)
		(?′ . ?')  (?″ . ?\") (?¥ . ?\\) (?$ . ?$)  (?% . ?%)
		(?# . ?#)  (?& . ?&)  (?* . ?*)  (?@ . ?@)
		(?0 . ?0)  (?1 . ?1)  (?2 . ?2)  (?3 . ?3)  (?4 . ?4)
		(?5 . ?5)  (?6 . ?6)  (?7 . ?7)  (?8 . ?8)  (?9 . ?9)
		(?A . ?A)  (?B . ?B)  (?C . ?C)  (?D . ?D)  (?E . ?E)
		(?F . ?F)  (?G . ?G)  (?H . ?H)  (?I . ?I)  (?J . ?J)
		(?K . ?K)  (?L . ?L)  (?M . ?M)  (?N . ?N)  (?O . ?O)
		(?P . ?P)  (?Q . ?Q)  (?R . ?R)  (?S . ?S)  (?T . ?T)
		(?U . ?U)  (?V . ?V)  (?W . ?W)  (?X . ?X)  (?Y . ?Y)
		(?Z . ?Z)
		(?a . ?a)  (?b . ?b)  (?c . ?c)  (?d . ?d)  (?e . ?e)
		(?f . ?f)  (?g . ?g)  (?h . ?h)  (?i . ?i)  (?j . ?j)
		(?k . ?k)  (?l . ?l)  (?m . ?m)  (?n . ?n)  (?o . ?o)
		(?p . ?p)  (?q . ?q)  (?r . ?r)  (?s . ?s)  (?t . ?t)
		(?u . ?u)  (?v . ?v)  (?w . ?w)  (?x . ?x)  (?y . ?y)
		(?z . ?z))
	       (Chinese-GB
		(?  . ?\ ) (?, . ?,)  (?. . ?.)  (?、 . ?,)  (?。 . ?.)
		(?: . ?:)  (?; . ?\;) (?? . ??)  (?! . ?!)
		(?` . ?`)  (?^ . ?^)  (?_ . ?_)  (? ̄ . ?~)
		(?― . ?-)
		(?/ . ?/)  (?\ . ?\\) (?~ . ?~)  (?| . ?|)
		(?‘ . ?`)  (?’ . ?')  (?“ . ?\") (?” . ?\")
		(?( . ?\() (?) . ?\)) (?[ . ?\[)  ( ?] . ?\])
		(?{ . ?{)  (?} . ?})
		(?+ . ?+)  (?- . ?-)  (?= . ?=)  (?< . ?<)  (?> . ?>)
		(?' . ?')  (?" . ?\") (?¥ . ?$)  (?% . ?%)
		(?# . ?#)  (?& . ?&)  (?* . ?*)  (?@ . ?@)
		(?0 . ?0)  (?1 . ?1)  (?2 . ?2)  (?3 . ?3)  (?4 . ?4)
		(?5 . ?5)  (?6 . ?6)  (?7 . ?7)  (?8 . ?8)  (?9 . ?9)
		(?A . ?A)  (?B . ?B)  (?C . ?C)  (?D . ?D)  (?E . ?E)
		(?F . ?F)  (?G . ?G)  (?H . ?H)  (?I . ?I)  (?J . ?J)
		(?K . ?K)  (?L . ?L)  (?M . ?M)  (?N . ?N)  (?O . ?O)
		(?P . ?P)  (?Q . ?Q)  (?R . ?R)  (?S . ?S)  (?T . ?T)
		(?U . ?U)  (?V . ?V)  (?W . ?W)  (?X . ?X)  (?Y . ?Y)
		(?Z . ?Z)
		(?a . ?a)  (?b . ?b)  (?c . ?c)  (?d . ?d)  (?e . ?e)
		(?f . ?f)  (?g . ?g)  (?h . ?h)  (?i . ?i)  (?j . ?j)
		(?k . ?k)  (?l . ?l)  (?m . ?m)  (?n . ?n)  (?o . ?o)
		(?p . ?p)  (?q . ?q)  (?r . ?r)  (?s . ?s)  (?t . ?t)
		(?u . ?u)  (?v . ?v)  (?w . ?w)  (?x . ?x)  (?y . ?y)
		(?z . ?z))
	       (Chinese-CNS
		(?  . ?\ ) (?, . ?,)  (?. . ?.)  (?、 . ?,)  (?。 . ?.)
		(?: . ?:)  (?; . ?\;) (?? . ??)  (?! . ?!)
		(?‵ . ?')  (?′ . ?`)  (?︿ . ?^)  (?_ . ?_)  (?‾ . ?~)
		(?﹣ . ?-)
		(?/ . ?/)  (?\ . ?\\) (?∕ . ?/)  (?﹨ . ?\\)
		(?∼ . ?~)  (?| . ?|)
		(?‘ . ?`)  (?’ . ?')
		(?〝 . ?\") (?〞 . ?\") (?“ . ?\") (?” . ?\")
		(?( . ?\() (?) . ?\))
		(?〔 . ?\[)  (?〕 . ?\])  (?﹝ . ?\[)  (?﹞ . ?\])
		(?{ . ?{)  (?} . ?})  (?﹛ . ?{)  (?﹜ . ?})
		(?〈 . ?<)  (?〉 . ?>)
		(?+ . ?+)  (?- . ?-)  (?= . ?=)  (?< . ?<)  (?> . ?>)
		(?$ . ?$)  (?% . ?%)
		(?# . ?#)  (?& . ?&)  (?* . ?*)  (?@ . ?@)
		(?0 . ?0)  (?1 . ?1)  (?2 . ?2)  (?3 . ?3)  (?4 . ?4)
		(?5 . ?5)  (?6 . ?6)  (?7 . ?7)  (?8 . ?8)  (?9 . ?9)
		(?A . ?A)  (?B . ?B)  (?C . ?C)  (?D . ?D)  (?E . ?E)
		(?F . ?F)  (?G . ?G)  (?H . ?H)  (?I . ?I)  (?J . ?J)
		(?K . ?K)  (?L . ?L)  (?M . ?M)  (?N . ?N)  (?O . ?O)
		(?P . ?P)  (?Q . ?Q)  (?R . ?R)  (?S . ?S)  (?T . ?T)
		(?U . ?U)  (?V . ?V)  (?W . ?W)  (?X . ?X)  (?Y . ?Y)
		(?Z . ?Z)
		(?a . ?a)  (?b . ?b)  (?c . ?c)  (?d . ?d)  (?e . ?e)
		(?f . ?f)  (?g . ?g)  (?h . ?h)  (?i . ?i)  (?j . ?j)
		(?k . ?k)  (?l . ?l)  (?m . ?m)  (?n . ?n)  (?o . ?o)
		(?p . ?p)  (?q . ?q)  (?r . ?r)  (?s . ?s)  (?t . ?t)
		(?u . ?u)  (?v . ?v)  (?w . ?w)  (?x . ?x)  (?y . ?y)
		(?z . ?z))
	       (Korean
		(?  . ?\ ) (?, . ?,)  (?. . ?.)
		(?: . ?:)  (?; . ?\;) (?? . ??)  (?! . ?!)
		(?’ . ?')  (?‘ . ?`)  (?^ . ?^)  (?_ . ?_)  (? ̄ . ?~)
		(?― . ?-)  (?­ . ?-)
		(?/ . ?/)  (?\ . ?\\) (?∼ . ?~)  (?| . ?|)
		(?‘ . ?`)  (?’ . ?')  (?“ . ?\") (?” . ?\")
		(?( . ?\() (?) . ?\)) (?[ . ?\[)  (?] . ?\])
		(?{ . ?{)  (?} . ?})  (?〈 . ?<)  (?〉 . ?>)
		(?+ . ?+)  (?- . ?-)  (?= . ?=)  (?< . ?<)  (?> . ?>)
		(?' . ?')  (?" . ?\") (?₩ . ?\\) (?$ . ?$)  (?% . ?%)
		(?# . ?#)  (?& . ?&)  (?* . ?*)  (?@ . ?@)
		(?0 . ?0)  (?1 . ?1)  (?2 . ?2)  (?3 . ?3)  (?4 . ?4)
		(?5 . ?5)  (?6 . ?6)  (?7 . ?7)  (?8 . ?8)  (?9 . ?9)
		(?A . ?A)  (?B . ?B)  (?C . ?C)  (?D . ?D)  (?E . ?E)
		(?F . ?F)  (?G . ?G)  (?H . ?H)  (?I . ?I)  (?J . ?J)
		(?K . ?K)  (?L . ?L)  (?M . ?M)  (?N . ?N)  (?O . ?O)
		(?P . ?P)  (?Q . ?Q)  (?R . ?R)  (?S . ?S)  (?T . ?T)
		(?U . ?U)  (?V . ?V)  (?W . ?W)  (?X . ?X)  (?Y . ?Y)
		(?Z . ?Z)
		(?a . ?a)  (?b . ?b)  (?c . ?c)  (?d . ?d)  (?e . ?e)
		(?f . ?f)  (?g . ?g)  (?h . ?h)  (?i . ?i)  (?j . ?j)
		(?k . ?k)  (?l . ?l)  (?m . ?m)  (?n . ?n)  (?o . ?o)
		(?p . ?p)  (?q . ?q)  (?r . ?r)  (?s . ?s)  (?t . ?t)
		(?u . ?u)  (?v . ?v)  (?w . ?w)  (?x . ?x)  (?y . ?y)
		(?z . ?z))))
      (hash (make-vector 100 nil))
      lang pair)
  (while table
    (setq lang (caar table)
	  pair (cdar table)
	  table (cdr table))
    (while pair
      (set (intern (char-to-string (caar pair)) its-full-half-table)
	   (cdar pair))
      (set (intern (concat (symbol-name lang) (char-to-string (cdar pair)))
		   its-half-full-table)
	   (caar pair))
      (setq pair (cdr pair)))
    hash))
----------------------------------------------------------------------

And if I do following steps

1. Download its.el.
2. Start emacs with `emacs -Q'.
3. Open its.el.
4. Mark above lines as region
5. M-x toggle-debug-on-error
6. M-x eval-region

Then I get following backtrace.

----------------------------------------------------------------------
Debugger entered--Lisp error: (wrong-type-argument obarrayp [nil nil nil nil nil nil nil nil nil nil nil nil nil nil nil nil nil nil nil nil nil nil nil nil nil nil nil nil nil nil nil nil nil nil nil nil nil nil nil nil nil nil nil nil nil nil nil nil nil nil ...])
  intern(" " [nil nil nil nil nil nil nil nil nil nil nil nil nil nil nil nil nil nil nil nil nil nil nil nil nil nil nil nil nil nil nil nil nil nil nil nil nil nil nil nil nil nil nil nil nil nil nil nil nil nil ...])
  (set (intern (char-to-string (car (car pair))) its-full-half-table) (cdr (car pair)))
  (while pair (set (intern (char-to-string (car (car pair))) its-full-half-table) (cdr (car pair))) (set (intern (concat (symbol-name lang) (char-to-string (cdr (car pair)))) its-half-full-table) (car (car pair))) (setq pair (cdr pair)))
  (while table (progn (setq lang (car (car table))) (setq pair (cdr (car table))) (setq table (cdr table))) (while pair (set (intern (char-to-string (car (car pair))) its-full-half-table) (cdr (car pair))) (set (intern (concat (symbol-name lang) (char-to-string (cdr (car pair)))) its-half-full-table) (car (car pair))) (setq pair (cdr pair))) hash)
  (let ((table '((Japanese (12288 . 32) (65292 . 44) (65294 . 46) (12289 . 44) (12290 . 46) (65306 . 58) (65307 . 59) (65311 . 63) (65281 . 33) (180 . 39) (65344 . 96) (65342 . 94) (65343 . 95) (65507 . 126) (12540 . 45) (8212 . 45) (8208 . 45) (65295 . 47) (65340 . 92) (12316 . 126) (65372 . 124) (8216 . 96) (8217 . 39) (8220 . 34) (8221 . 34) (65288 . 40) (65289 . 41) (65339 . 91) (65341 . 93) (65371 . 123) (65373 . 125) (12296 . 60) (12297 . 62) (65291 . 43) (8722 . 45) (65309 . 61) (65308 . 60) (65310 . 62) (8242 . 39) (8243 . 34) (65509 . 92) (65284 . 36) (65285 . 37) (65283 . 35) (65286 . 38) (65290 . 42) (65312 . 64) (65296 . 48) (65297 . 49) ...) (Chinese-GB (12288 . 32) (65292 . 44) (65294 . 46) (12289 . 44) (12290 . 46) (65306 . 58) (65307 . 59) (65311 . 63) (65281 . 33) (65344 . 96) (65342 . 94) (65343 . 95) (65507 . 126) (8213 . 45) (65295 . 47) (65340 . 92) (65374 . 126) (65372 . 124) (8216 . 96) (8217 . 39) (8220 . 34) (8221 . 34) (65288 . 40) (65289 . 41) (65339 . 91) (65341 . 93) (65371 . 123) (65373 . 125) (65291 . 43) (65293 . 45) (65309 . 61) (65308 . 60) (65310 . 62) (65287 . 39) (65282 . 34) (65509 . 36) (65285 . 37) (65283 . 35) (65286 . 38) (65290 . 42) (65312 . 64) (65296 . 48) (65297 . 49) (65298 . 50) (65299 . 51) (65300 . 52) (65301 . 53) (65302 . 54) (65303 . 55) ...) (Chinese-CNS (12288 . 32) (65292 . 44) (65294 . 46) (12289 . 44) (12290 . 46) (65306 . 58) (65307 . 59) (65311 . 63) (65281 . 33) (8245 . 39) (8242 . 96) (65087 . 94) (65343 . 95) (8254 . 126) (65123 . 45) (65295 . 47) (65340 . 92) (8725 . 47) (65128 . 92) (8764 . 126) (65372 . 124) (8216 . 96) (8217 . 39) (12317 . 34) (12318 . 34) (8220 . 34) (8221 . 34) (65288 . 40) (65289 . 41) (12308 . 91) (12309 . 93) (65117 . 91) (65118 . 93) (65371 . 123) (65373 . 125) (65115 . 123) (65116 . 125) (12296 . 60) (12297 . 62) (65291 . 43) (65293 . 45) (65309 . 61) (65308 . 60) (65310 . 62) (65284 . 36) (65285 . 37) (65283 . 35) (65286 . 38) (65290 . 42) ...) (Korean (12288 . 32) (65292 . 44) (65294 . 46) (65306 . 58) (65307 . 59) (65311 . 63) (65281 . 33) (8217 . 39) (8216 . 96) (65342 . 94) (65343 . 95) (65507 . 126) (8213 . 45) (173 . 45) (65295 . 47) (65340 . 92) (8764 . 126) (65372 . 124) (8216 . 96) (8217 . 39) (8220 . 34) (8221 . 34) (65288 . 40) (65289 . 41) (65339 . 91) (65341 . 93) (65371 . 123) (65373 . 125) (12296 . 60) (12297 . 62) (65291 . 43) (65293 . 45) (65309 . 61) (65308 . 60) (65310 . 62) (65287 . 39) (65282 . 34) (65510 . 92) (65284 . 36) (65285 . 37) (65283 . 35) (65286 . 38) (65290 . 42) (65312 . 64) (65296 . 48) (65297 . 49) (65298 . 50) (65299 . 51) (65300 . 52) ...))) (hash (make-vector 100 nil)) lang pair) (while table (progn (setq lang (car (car table))) (setq pair (cdr (car table))) (setq table (cdr table))) (while pair (set (intern (char-to-string (car (car pair))) its-full-half-table) (cdr (car pair))) (set (intern (concat (symbol-name lang) (char-to-string (cdr ...))) its-half-full-table) (car (car pair))) (setq pair (cdr pair))) hash))
  eval-region(42971 48417)  ; Reading at buffer position 48417
  funcall-interactively(eval-region 42971 48417)
  command-execute(eval-region record)
  execute-extended-command(nil "eval-region" "eval-reg")
  funcall-interactively(execute-extended-command nil "eval-region" "eval-reg")
  command-execute(execute-extended-command)
----------------------------------------------------------------------

  reply	other threads:[~2024-03-04  8:41 UTC|newest]

Thread overview: 8+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2024-03-04  6:04 bug#69536: 30.0.50; Runtime error happens with Tamago input method after recent change with obarry Yasuhiro Kimura
2024-03-04  8:41 ` Yasuhiro Kimura [this message]
2024-03-04 12:20 ` Eli Zaretskii
2024-03-04 13:48 ` Mattias Engdegård
2024-03-05  7:20   ` Yasuhiro Kimura
2024-03-05  8:40     ` Yasuhiro Kimura
2024-03-05 12:32     ` Eli Zaretskii
2024-03-09  8:39       ` Eli Zaretskii

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

  List information: https://www.gnu.org/software/emacs/

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20240304.174145.1968255587035225823.yasu@utahime.org \
    --to=yasu@utahime.org \
    --cc=69536@debbugs.gnu.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
Code repositories for project(s) associated with this public inbox

	https://git.savannah.gnu.org/cgit/emacs.git

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).