[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [Scheme-reports] Write procedure is not backwards compatible
Ouch! If true, I second this comment. Backward compatibility for write is pretty important. Consider the case of running an R5RS (or R7RS) program in an R7RS implementation to generate a file that will be consumed by an R5RS implementation.
There is no mention of this incompatibility in the section "Language changes since R5RS".
Jonathan
On Jul 1, 2012, at 12:36 AM, Marc Feeley wrote:
> Formal Comment
>
> Submitter's name: Marc Feeley
> Submitter's email: feeley at iro.umontreal.ca
> Relevant draft: r7rs draft 6
>
> Type: defect
> Priority: major
> Relevant section of draft: 6.13.3. Output
>
> Summary: Write procedure is not backwards compatible
>
> R7RS introduces a new output procedure called write-simple, which has
> the same semantics as the R5RS write procedure. On the other hand,
> the R7RS write procedure handles shared structures differently than
> the R5RS. For example :
>
> (let ((x (list 1 2))) (write (list x x)))
>
> displays ((1 2) (1 2)) in an R5RS system
> and displays (#0=(1 2) #0#) in an R7RS system
>
> To preserve backwards compatibility, it is the version of the write
> procedure which uses datum labels which should have a different name.
> In fact SRFI-38 has specified the name write-with-shared-structure for
> this output procedure. This name should be maintained since it has
> been implemented with that name in some Scheme systems.
>
>
> _______________________________________________
> Scheme-reports mailing list
> Scheme-reports@x
> http://lists.scheme-reports.org/cgi-bin/mailman/listinfo/scheme-reports
_______________________________________________
Scheme-reports mailing list
Scheme-reports@x
http://lists.scheme-reports.org/cgi-bin/mailman/listinfo/scheme-reports