+;;; Check for error detection of illegal directives in a~<..~> justify
+;;; block (see ANSI section 22.3.5.2)
+(assert (raises-error? (format nil "~<~W~>" 'foo)))
+(assert (raises-error? (format nil "~<~<~A~:>~>" '(foo))))
+(assert (string= (format nil "~<~<~A~>~>" 'foo) "FOO"))
+
+;;; Check that arrays that we print while *PRINT-READABLY* is true are
+;;; in fact generating similar objects.
+(assert (equal (array-dimensions
+ (read-from-string
+ (with-output-to-string (s)
+ (let ((*print-readably* t))
+ (print (make-array '(1 2 0)) s)))))
+ '(1 2 0)))
+
+(assert (multiple-value-bind (result error)
+ (ignore-errors (read-from-string
+ (with-output-to-string (s)
+ (let ((*print-readably* t))
+ (print (make-array '(1 0 1)) s)))))
+ ;; it might not be readably-printable
+ (or (typep error 'print-not-readable)
+ ;; or else it had better have the same dimensions
+ (equal (array-dimensions result) '(1 0 1)))))
+
+;;; before 0.8.0.66 it signalled UNBOUND-VARIABLE
+(write #(1 2 3) :pretty nil :readably t)
+
+;;; another UNBOUND-VARIABLE, this time due to a bug in FORMATTER
+;;; expanders.
+(funcall (formatter "~@<~A~:*~A~:>") nil 3)
+