Extensibility (and the lack thereof) Marc Nieper-Wißkirchen (28 Aug 2020 11:49 UTC)
Re: Extensibility (and the lack thereof) Felix Thibault (28 Aug 2020 18:06 UTC)
Re: Extensibility (and the lack thereof) Marc Nieper-Wißkirchen (28 Aug 2020 19:22 UTC)
Re: Extensibility (and the lack thereof) John Cowan (29 Aug 2020 00:46 UTC)
Re: Extensibility (and the lack thereof) Marc Nieper-Wißkirchen (29 Aug 2020 08:14 UTC)
Re: Extensibility (and the lack thereof) Wolfgang Corcoran-Mathe (26 Oct 2020 17:50 UTC)
Re: Extensibility (and the lack thereof) John Cowan (26 Oct 2020 20:04 UTC)
Re: Extensibility (and the lack thereof) Marc Nieper-Wißkirchen (26 Oct 2020 20:33 UTC)
Re: Extensibility (and the lack thereof) Felix Thibault (26 Oct 2020 21:17 UTC)
Re: Extensibility (and the lack thereof) Marc Nieper-Wißkirchen (26 Oct 2020 21:30 UTC)
Re: Extensibility (and the lack thereof) Felix Thibault (26 Oct 2020 22:42 UTC)
Re: Extensibility (and the lack thereof) Felix Thibault (26 Oct 2020 22:49 UTC)
Re: Extensibility (and the lack thereof) John Cowan (27 Oct 2020 00:05 UTC)
Re: Extensibility (and the lack thereof) Felix Thibault (27 Oct 2020 00:35 UTC)
Re: Extensibility (and the lack thereof) John Cowan (27 Oct 2020 01:59 UTC)
Re: Extensibility (and the lack thereof) Felix Thibault (27 Oct 2020 02:18 UTC)
Re: Extensibility (and the lack thereof) Wolfgang Corcoran-Mathe (27 Oct 2020 19:38 UTC)
Re: Extensibility (and the lack thereof) Marc Nieper-Wißkirchen (27 Oct 2020 19:46 UTC)
Re: Extensibility (and the lack thereof) Marc Nieper-Wißkirchen (28 Oct 2020 06:31 UTC)
Re: Extensibility (and the lack thereof) Felix Thibault (28 Oct 2020 21:30 UTC)
Re: Extensibility (and the lack thereof) John Cowan (29 Oct 2020 00:17 UTC)
Re: Extensibility (and the lack thereof) Marc Nieper-Wißkirchen (29 Oct 2020 16:42 UTC)
Re: Extensibility (and the lack thereof) Marc Nieper-Wißkirchen (27 Oct 2020 17:20 UTC)
Re: Extensibility (and the lack thereof) Felix Thibault (27 Oct 2020 18:42 UTC)

Re: Extensibility (and the lack thereof) Felix Thibault 27 Oct 2020 02:18 UTC

Ok, I think I'll add an example with (match (proc obj) (pattern ...))
to the extension section and say something like "there will be a
future srfi using the syntax -> and => and an analogous technique to
accomplish this."

Felix

On Mon, Oct 26, 2020 at 9:58 PM John Cowan <xxxxxx@ccil.org> wrote:
>
>
>
> On Mon, Oct 26, 2020 at 8:35 PM Felix Thibault <xxxxxx@gmail.com> wrote:n
>
>> Wait, is this like (match (view-proc obj) pattern ...)) ?
>
>
> That was my original idea, but now I think it's better to do it differently.  I'm going to stick with -> for now, as I think it helps readability.  Here's an example:
>
> (define-record-type <point>
>   (make-point x y)
>   point?
>   (x point-x)
>   (y point-y))
>
> (define (point-view pt)
>   (if (point? pt)
>    (values (point-x pt) (point-y pt))
>    (values))
>
> (define p (make-point 10 20))
>
> (match p
>   ((-> point? point-view 10 y)
>     (+ y 1))) => 21
>
> (match p
>   ((-> point? point-view x 10)
>    (- x 1))) => error
>
> That allows `match` users to match against any type for which a view-proc can be created  (it need not be a record type), so I don't think we need any of the other bells and whistles.  Note that if view-proc returns zero values, the -> pattern fails.  (That's a usable convention, but not ideal.)
>
>
>
> John Cowan          http://vrici.lojban.org/~cowan        xxxxxx@ccil.org
> There is a Darwinian explanation for the refusal to accept Darwin.
> Given the very pessimistic conclusions about moral purpose to which his
> theory drives us, and given the importance of a sense of moral purpose
> in helping us cope with life, a refusal to believe Darwin's theory may
> have important survival value. --Ian Johnston
>