Re: [Scheme-reports] Some comments after reading the r7rs public draft Alex Shinn (11 Jun 2012 04:24 UTC)

Re: [Scheme-reports] Some comments after reading the r7rs public draft Alex Shinn 11 Jun 2012 04:23 UTC

On Mon, Jun 11, 2012 at 12:57 PM, John Cowan <cowan@mercury.ccil.org> wrote:
> Alex Shinn scripsit:
>
>> Chibi-scheme allows implicit forcing as a compile time option (probably
>> eventually to be a language-level option), and has a formal definition
>> of which primitives can and can't perform implicit forcing.
>
> Is this written down anywhere?  I wasn't able to find it.

Not documented, per se, but basically _all_ primitives
except constructors (opcode class SEXP_OPC_CONSTRUCTOR)
auto-forced their arguments.  I should probably change
that so that mutators (e.g. the second arg to vector-set!)
are not auto-forced.

(not (make-promise #f)) is an interesting case.  It's
unspecified as far as the standard is concerned, and
I don't see any reason to deviate from the above rules
for it, so Chibi will continue to return #t here.

I think it's reasonable to say "it is an error if the
forced expression raises an exception."

The other cases I think should always be auto-forced -
they would simply be errors anyway.

--
Alex

_______________________________________________
Scheme-reports mailing list
Scheme-reports@scheme-reports.org
http://lists.scheme-reports.org/cgi-bin/mailman/listinfo/scheme-reports