comparison lisp/international/ccl.el @ 29030:837bc0327945

(ccl-compile-write-string): Make STR unibyte. (ccl-compile-write-repeat): If ARG is string, make it unibyte.
author Kenichi Handa <handa@m17n.org>
date Sat, 20 May 2000 02:23:35 +0000
parents 1b7866e465bd
children 203427c54c10
comparison
equal deleted inserted replaced
29029:99c561e74d0d 29030:837bc0327945
510 (logior (ash op 3) (get right 'ccl-register-number)) 510 (logior (ash op 3) (get right 'ccl-register-number))
511 left))))) 511 left)))))
512 512
513 ;; Compile WRITE statement with string argument. 513 ;; Compile WRITE statement with string argument.
514 (defun ccl-compile-write-string (str) 514 (defun ccl-compile-write-string (str)
515 (setq str (string-as-unibyte str))
515 (let ((len (length str))) 516 (let ((len (length str)))
516 (ccl-embed-code 'write-const-string 1 len) 517 (ccl-embed-code 'write-const-string 1 len)
517 (ccl-embed-string len str)) 518 (ccl-embed-string len str))
518 nil) 519 nil)
519 520
721 (let ((arg (nth 1 cmd))) 722 (let ((arg (nth 1 cmd)))
722 (cond ((integerp arg) 723 (cond ((integerp arg)
723 (ccl-embed-code 'write-const-jump 0 ccl-loop-head) 724 (ccl-embed-code 'write-const-jump 0 ccl-loop-head)
724 (ccl-embed-data arg)) 725 (ccl-embed-data arg))
725 ((stringp arg) 726 ((stringp arg)
727 (setq arg (string-as-unibyte arg))
726 (let ((len (length arg)) 728 (let ((len (length arg))
727 (i 0)) 729 (i 0))
728 (ccl-embed-code 'write-string-jump 0 ccl-loop-head) 730 (ccl-embed-code 'write-string-jump 0 ccl-loop-head)
729 (ccl-embed-data len) 731 (ccl-embed-data len)
730 (ccl-embed-string len arg))) 732 (ccl-embed-string len arg)))