Parse raw slot data when printing structures in LDB
[sbcl.git] / tests / symbol.impure.lisp
blobe10c8c76fd6df2084dfa8c7476cea3b1236bf80b
1 ;;;; miscellaneous impure tests of SYMBOL-related stuff
3 ;;;; This software is part of the SBCL system. See the README file for
4 ;;;; more information.
5 ;;;;
6 ;;;; While most of SBCL is derived from the CMU CL system, the test
7 ;;;; files (like this one) were written from scratch after the fork
8 ;;;; from CMU CL.
9 ;;;;
10 ;;;; This software is in the public domain and is provided with
11 ;;;; absolutely no warranty. See the COPYING and CREDITS files for
12 ;;;; more information.
14 (in-package "CL-USER")
16 (declaim (type (simple-array fixnum (*)) *foo*))
17 (with-test (:name :defvar-type-error)
18 (assert (eq :ok
19 (handler-case
20 (eval `(defvar *foo* (make-array 10 :element-type '(unsigned-byte 60))))
21 (type-error (e)
22 (when (and (typep e 'type-error)
23 (equal '(simple-array fixnum (*))
24 (type-error-expected-type e)))
25 ;; Check that it prints without an error.
26 (let ((string (princ-to-string e)))
27 :ok)))))))