comments Marc Feeley (04 May 2020 21:21 UTC)
Re: comments John Cowan (04 May 2020 21:24 UTC)
Re: comments Marc Feeley (04 May 2020 21:33 UTC)
Re: comments John Cowan (04 May 2020 21:59 UTC)
Re: comments Marc Feeley (05 May 2020 00:29 UTC)
Re: comments Marc Nieper-Wißkirchen (05 May 2020 06:35 UTC)
Re: comments Marc Nieper-Wißkirchen (05 May 2020 08:09 UTC)
Re: comments Marc Nieper-Wißkirchen (05 May 2020 06:21 UTC)
Re: comments Marc Nieper-Wißkirchen (17 Aug 2020 14:47 UTC)
Re: comments Marc Nieper-Wißkirchen (17 Aug 2020 14:48 UTC)

comments Marc Feeley 04 May 2020 21:21 UTC

It should be specified that it is an error to call set-box! with a number of values that is different than the number of values in the box being set.  In other words, set-box! does not allocate memory.

Your extension to boxes reminds me of how multiple values are implemented in Gambit, with a “values object” which is in effect SRFI 195 boxes, in the sense that (box A B C) is Gambit’s (values A B C).  For that reason I would like your SRFI to specify that it is allowed, but not required, that

       (box X ...)  is equivalent to  (values X ...)
       (unbox b)    is equivalent to  b

Marc