[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: Threading / Pipe Macro (Chris Vine, Mark H Weaver)
From: |
Chris Vine |
Subject: |
Re: Threading / Pipe Macro (Chris Vine, Mark H Weaver) |
Date: |
Tue, 9 Jul 2019 10:58:23 +0100 |
On Tue, 09 Jul 2019 11:40:02 +0200
Linus Björnstam <address@hidden> wrote:
> Sorry, I didn't see that macro. I was referring to my macro that Erik
> linked to [1], which is a syntax rules macro that also allows for <>
> argument placeholders:
>
> (~> 1 1+ (/ 10 <>) iota (+ <...>)) => 10
>
> It defaults to left insert, so
>
> (~> 10 (/ 2)) => 5
>
> but also (like the syntax rules macro i posted) also supports functions
> without parents as you can see in the first example.
>
> That's what I get for trying to.follow the discussion in an unthreaded mobile
> app :)
>
> [1]: https://bitbucket.org/bjoli/guile-threading-macros/src/default/
I thought your module/library was impressive. My little macro (as it
now turns out, defective in hygiene, although it has served me well for
some time) was something I use frequently because I like the pipeline
idiom. It inserts to the right only, because that is what I am used
to: it sort-of imitates the reverse application of a partially applied
curried function. I think your module is based on clojure macros,
about which I know little.
- Re: Threading / Pipe Macro (Chris Vine, Mark H Weaver), Zelphir Kaltstahl, 2019/07/08
- Re: Threading / Pipe Macro (Chris Vine, Mark H Weaver), Chris Vine, 2019/07/08
- Re: Threading / Pipe Macro (Chris Vine, Mark H Weaver), Linus Björnstam, 2019/07/09
- Message not available
- Re: Threading / Pipe Macro (Chris Vine, Mark H Weaver), Chris Vine, 2019/07/09
- Re: Threading / Pipe Macro (Chris Vine, Mark H Weaver), Linus Björnstam, 2019/07/09
- Re: Threading / Pipe Macro (Chris Vine, Mark H Weaver),
Chris Vine <=
- Re: Threading / Pipe Macro (Chris Vine, Mark H Weaver), Linus Björnstam, 2019/07/09