write/ss only falls back on write in unknown cases.

This commit is contained in:
Alex Shinn 2013-08-11 12:38:43 +09:00
parent 325b3e20b3
commit af71abc817

View file

@ -106,7 +106,14 @@
((let ((type (type-of x)))
(and (type? type) (type-printer type)))
=> (lambda (printer) (printer x wr out)))
((null? x) (display "()" out))
((char? x) (display "#\\" out) (write-char x out))
((symbol? x) (display (symbol->string x) out))
((number? x) (display (number->string x) out))
((eq? x #t) (display "#t" out))
((eq? x #f) (display "#f" out))
(else
;; (display "#<unknown>" out)
(write x out))))))))
(define write/ss write-with-shared-structure)