bug-gnu-emacs
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

bug#69536: 30.0.50; Runtime error happens with Tamago input method after


From: Yasuhiro Kimura
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)

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 via email to

[Prev in Thread] Current Thread [Next in Thread]