From dc4274101eb334f5c2eaa34d0973a40cfe552943 Mon Sep 17 00:00:00 2001 From: pfdietz <pfdietz@localhost> Date: Wed, 2 Oct 2002 03:45:30 +0000 Subject: [PATCH] Fixed up some test problems, added comments, added simple-base-string.8 --- ansi-tests/char-schar.lsp | 6 +++--- ansi-tests/map.lsp | 2 ++ ansi-tests/reader-test.lsp | 2 ++ ansi-tests/string.lsp | 4 ++++ 4 files changed, 11 insertions(+), 3 deletions(-) diff --git a/ansi-tests/char-schar.lsp b/ansi-tests/char-schar.lsp index aa15a32b..fc07c31c 100644 --- a/ansi-tests/char-schar.lsp +++ b/ansi-tests/char-schar.lsp @@ -23,14 +23,14 @@ "Xbcd" "aXcd" "abXd" "abcX") (deftest char.3 - (let ((s (make-array 6 :element-type 'chararacter + (let ((s (make-array 6 :element-type 'character :initial-contents '(#\a #\b #\c #\d #\e #\f)))) (setf (char s 3) #\X) s) "abcXef") (deftest char.4 - (let ((s (make-array 6 :element-type 'chararacter + (let ((s (make-array 6 :element-type 'character :initial-contents '(#\a #\b #\c #\d #\e #\f) :fill-pointer 4))) (setf (char s 3) #\X) @@ -56,7 +56,7 @@ "aaaXa") (deftest char.8 - (let ((s (make-array 6 :element-type 'chararacter + (let ((s (make-array 6 :element-type 'character :initial-contents '(#\a #\b #\c #\d #\e #\f) :fill-pointer 4))) (setf (char s 5) #\X) diff --git a/ansi-tests/map.lsp b/ansi-tests/map.lsp index 86d5b0f9..a513a72b 100644 --- a/ansi-tests/map.lsp +++ b/ansi-tests/map.lsp @@ -125,10 +125,12 @@ (map '(simple-vector character) #'identity '(#\a #\b #\c #\d #\e)) "abcde") +;;; Use a more elaborate form of the simple-array type specifier (deftest map-string.31 (map '(simple-array character *) #'identity "abcde") "abcde") +;;; Use a more elaborate form of the simple-array type specifier (deftest map-string.32 (map '(simple-array character 5) #'identity "abcde") "abcde") diff --git a/ansi-tests/reader-test.lsp b/ansi-tests/reader-test.lsp index 40120456..817de73a 100644 --- a/ansi-tests/reader-test.lsp +++ b/ansi-tests/reader-test.lsp @@ -97,6 +97,7 @@ "ABCD")))) t) +#| (deftest read-symbol-8 (multiple-value-bind (s n) (ignore-errors (read-from-string "::ABCD")) @@ -107,6 +108,7 @@ (string-equal (symbol-name s) "ABCD")))) t) +|# (defun read-symbol-9-body (natoms maxlen) (let* ((chars (concatenate 'string diff --git a/ansi-tests/string.lsp b/ansi-tests/string.lsp index 9de96d27..36b10956 100644 --- a/ansi-tests/string.lsp +++ b/ansi-tests/string.lsp @@ -108,6 +108,10 @@ (subtypep 'simple-base-string 'simple-string) t t) +(deftest simple-base-string.8 + (subtypep 'simple-base-string 'simple-vector) + t t) + ;;; Tests for simple-string-p (deftest simple-string-p.1 -- GitLab