This commit is contained in:
Alex Shinn 2011-03-06 16:56:35 +09:00
parent 91914d6739
commit bab88c01b4

View file

@ -11,25 +11,25 @@
(test 7 (string-length "Русский")) (test 7 (string-length "Русский"))
(test #\(string-ref "二本語" 0)) (test #\(string-ref "日本語" 0))
(test #\本 (string-ref "本語" 1)) (test #\本 (string-ref "本語" 1))
(test #\語 (string-ref "本語" 2)) (test #\語 (string-ref "本語" 2))
(test 3 (string-length "本語")) (test 3 (string-length "本語"))
(test '(#\#\本 #\語) (string->list "二本語")) (test '(#\#\本 #\語) (string->list "日本語"))
(test "二本語" (list->string '(#\二 #\本 #\語))) (test "日本語" (list->string '(#\日 #\本 #\語)))
(test "二本" (substring "二本語" 0 2)) (test "日本" (substring "日本語" 0 2))
(test "本語" (substring "本語" 1 3)) (test "本語" (substring "本語" 1 3))
(test "-語" (test "-語"
(let ((s (substring "本語" 0 3))) (let ((s (substring "本語" 0 3)))
(string-set! s 1 #\-) (string-set! s 1 #\-)
s)) s))
(test "本人" (test "本人"
(let ((s (substring "本語" 0 3))) (let ((s (substring "本語" 0 3)))
(string-set! s 2 #\人) (string-set! s 2 #\人)
s)) s))