From 16b427b8c45c1790a5555e5e8be5c666fe53b35c Mon Sep 17 00:00:00 2001 From: OGINO Masanori Date: Wed, 22 Jul 2015 23:06:46 +0900 Subject: [PATCH] Fix typo, alerm -> alarm. This commit also enables some tests to catch more regressions. Signed-off-by: OGINO Masanori --- contrib/20.r7rs/t/r7rs.scm | 16 ++++++++-------- extlib/benz/read.c | 2 +- 2 files changed, 9 insertions(+), 9 deletions(-) diff --git a/contrib/20.r7rs/t/r7rs.scm b/contrib/20.r7rs/t/r7rs.scm index e7adaf65..4185724d 100644 --- a/contrib/20.r7rs/t/r7rs.scm +++ b/contrib/20.r7rs/t/r7rs.scm @@ -2099,14 +2099,14 @@ ;; (test-read-error "(#; #;x #;y . z)") ;; (test-read-error "(#; #;x . z)") -;; (test #\a (read (open-input-string "#\\a"))) -;; (test #\space (read (open-input-string "#\\space"))) -;; (test 0 (char->integer (read (open-input-string "#\\null")))) -;; (test 7 (char->integer (read (open-input-string "#\\alarm")))) -;; (test 8 (char->integer (read (open-input-string "#\\backspace")))) -;; (test 9 (char->integer (read (open-input-string "#\\tab")))) -;; (test 10 (char->integer (read (open-input-string "#\\newline")))) -;; (test 13 (char->integer (read (open-input-string "#\\return")))) +(test #\a (read (open-input-string "#\\a"))) +(test #\space (read (open-input-string "#\\space"))) +(test 0 (char->integer (read (open-input-string "#\\null")))) +(test 7 (char->integer (read (open-input-string "#\\alarm")))) +(test 8 (char->integer (read (open-input-string "#\\backspace")))) +(test 9 (char->integer (read (open-input-string "#\\tab")))) +(test 10 (char->integer (read (open-input-string "#\\newline")))) +(test 13 (char->integer (read (open-input-string "#\\return")))) ;; (test #x7F (char->integer (read (open-input-string "#\\delete")))) ;; (test #x1B (char->integer (read (open-input-string "#\\escape")))) ;; (test #x03BB (char->integer (read (open-input-string "#\\λ")))) diff --git a/extlib/benz/read.c b/extlib/benz/read.c index 6051ecf7..1a735879 100644 --- a/extlib/benz/read.c +++ b/extlib/benz/read.c @@ -429,7 +429,7 @@ read_char(pic_state *pic, struct pic_port *port, int c) if (! isdelim(peek(pic, port))) { switch (c) { default: read_error(pic, "unexpected character after char literal"); - case 'a': c = '\a'; if (! expect(pic, port, "lerm")) goto fail; break; + case 'a': c = '\a'; if (! expect(pic, port, "larm")) goto fail; break; case 'b': c = '\b'; if (! expect(pic, port, "ackspace")) goto fail; break; case 'd': c = 0x7F; if (! expect(pic, port, "elete")) goto fail; break; case 'e': c = 0x1B; if (! expect(pic, port, "scape")) goto fail; break;