[plt-scheme] What is the default object writer?

From: Doug Orleans (dougorleans at gmail.com)
Date: Sun May 2 18:49:56 EDT 2010

On Sun, May 2, 2010 at 6:08 PM, Matthew Flatt <mflatt at cs.utah.edu> wrote:
> At Sun, 2 May 2010 17:59:28 -0400, Doug Orleans wrote:
>> Also, perhaps unrelated, but what exactly does the print-unreadable
>> parameter do? [...] it doesn't actually
>> say what the difference is between #t and #f.
> Good point.
> If you set the parameter to #f, then an attempt to print an unreadable
> value raises an exception.

Interesting.  Why does this not hold for the read-eval-print loop?

> (print-unreadable #f)
> (make-object (class object% (super-new)))
#(struct:object:stdin::374 ...)
> (print (make-object (class object% (super-new))))
write: printing disabled for unreadable value: #(struct:object:stdin::423 ...)

 === context ===

--dougorleans at gmail.com

Posted on the users mailing list.