unofficial mirror of guile-user@gnu.org 
 help / color / mirror / Atom feed
* argument threading macros & combinators for guile
       [not found] <1345689091.859703.1596743112863.ref@mail.yahoo.com>
@ 2020-08-06 19:45 ` vapnik spaknik
  2020-08-06 20:43   ` Linus Björnstam
  0 siblings, 1 reply; 5+ messages in thread
From: vapnik spaknik @ 2020-08-06 19:45 UTC (permalink / raw)
  To: guile users mailing list

Hi,
    does anyone know of guile modules containing argument threading macros & combinators, e.g. similar to dash.el & dash-functional.el for elisp?

Joe. 



^ permalink raw reply	[flat|nested] 5+ messages in thread

* Re: argument threading macros & combinators for guile
  2020-08-06 19:45 ` argument threading macros & combinators for guile vapnik spaknik
@ 2020-08-06 20:43   ` Linus Björnstam
  2020-08-06 20:50     ` Linus Björnstam
  2020-08-06 22:37     ` vapnik spaknik via General Guile related discussions
  0 siblings, 2 replies; 5+ messages in thread
From: Linus Björnstam @ 2020-08-06 20:43 UTC (permalink / raw)
  To: vapnik spaknik, guile users mailing list

I have some old ones over here: https://hg.sr.ht/~bjoli/guile-threading-macros

They are written using syntax-rules and I am not sure how well they combine with srfi-26. If srfi 26 exports auxiliary syntax, you won't be able to combine them since that syntax will shadow the unbound syntax <> and <...> used by my macros.


Other than that, we have a srfi called chain that might be finalized soon. That must be srfi 190-something.

-- 
  Linus Björnstam

On Thu, 6 Aug 2020, at 21:45, vapnik spaknik wrote:
> Hi,
>     does anyone know of guile modules containing argument threading 
> macros & combinators, e.g. similar to dash.el & dash-functional.el for 
> elisp?
> 
> Joe. 
> 
>



^ permalink raw reply	[flat|nested] 5+ messages in thread

* Re: argument threading macros & combinators for guile
  2020-08-06 20:43   ` Linus Björnstam
@ 2020-08-06 20:50     ` Linus Björnstam
  2020-08-06 22:37     ` vapnik spaknik via General Guile related discussions
  1 sibling, 0 replies; 5+ messages in thread
From: Linus Björnstam @ 2020-08-06 20:50 UTC (permalink / raw)
  To: vapnik spaknik, guile users mailing list

I forgot to say, that is a trivial fix! Just import the bindings from srfi 26 and re-export them.

This code can also be used to implement the new srfibchaij macro, although a syntax-case one would be about two billion times shorter (and faster). 

-- 
  Linus Björnstam

On Thu, 6 Aug 2020, at 22:43, Linus Björnstam wrote:
> I have some old ones over here: https://hg.sr.ht/~bjoli/guile-threading-macros
> 
> They are written using syntax-rules and I am not sure how well they 
> combine with srfi-26. If srfi 26 exports auxiliary syntax, you won't be 
> able to combine them since that syntax will shadow the unbound syntax 
> <> and <...> used by my macros.
> 
> 
> Other than that, we have a srfi called chain that might be finalized 
> soon. That must be srfi 190-something.
> 
> -- 
>   Linus Björnstam
> 
> On Thu, 6 Aug 2020, at 21:45, vapnik spaknik wrote:
> > Hi,
> >     does anyone know of guile modules containing argument threading 
> > macros & combinators, e.g. similar to dash.el & dash-functional.el for 
> > elisp?
> > 
> > Joe. 
> > 
> >
> 
>



^ permalink raw reply	[flat|nested] 5+ messages in thread

* Re: argument threading macros & combinators for guile
  2020-08-06 20:43   ` Linus Björnstam
  2020-08-06 20:50     ` Linus Björnstam
@ 2020-08-06 22:37     ` vapnik spaknik via General Guile related discussions
  2020-08-08 20:38       ` Linus Björnstam
  1 sibling, 1 reply; 5+ messages in thread
From: vapnik spaknik via General Guile related discussions @ 2020-08-06 22:37 UTC (permalink / raw)
  To: guile users mailing list, Linus Björnstam

 

>On Thursday, August 6, 2020, 09:43:53 PM GMT+1, Linus Björnstam <linus.internet@fastmail.se> wrote:

>I have some old ones over here: https://hg.sr.ht/~bjoli/guile-threading-macros

Thanks, that looks great Linus. Is there a guix package for them?  


^ permalink raw reply	[flat|nested] 5+ messages in thread

* Re: argument threading macros & combinators for guile
  2020-08-06 22:37     ` vapnik spaknik via General Guile related discussions
@ 2020-08-08 20:38       ` Linus Björnstam
  0 siblings, 0 replies; 5+ messages in thread
From: Linus Björnstam @ 2020-08-08 20:38 UTC (permalink / raw)
  To: vapnik spaknik, guile users mailing list

I thought about it recently, but with the upcoming srfi-197 (among others, the chain macro) it felt rather pointless. It does absolutely the same thing, and to my surprise I received a "thank you" for valuable input in the srfi document. I happened to suggest the same syntax I had settled on, taken from the cut macro in srfi-26 :)

I will probably submit a patch to guile with srfi-197 whenever it gets finalized. I don't know if Ludo or Andy are interested in including it, but if not it can easily be made a package. 

-- 
  Linus Björnstam

On Fri, 7 Aug 2020, at 00:37, vapnik spaknik wrote:
>  
> 
> >On Thursday, August 6, 2020, 09:43:53 PM GMT+1, Linus Björnstam <linus.internet@fastmail.se> wrote:
> 
> >I have some old ones over here: https://hg.sr.ht/~bjoli/guile-threading-macros
> 
> Thanks, that looks great Linus. Is there a guix package for them?



^ permalink raw reply	[flat|nested] 5+ messages in thread

end of thread, other threads:[~2020-08-08 20:38 UTC | newest]

Thread overview: 5+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
     [not found] <1345689091.859703.1596743112863.ref@mail.yahoo.com>
2020-08-06 19:45 ` argument threading macros & combinators for guile vapnik spaknik
2020-08-06 20:43   ` Linus Björnstam
2020-08-06 20:50     ` Linus Björnstam
2020-08-06 22:37     ` vapnik spaknik via General Guile related discussions
2020-08-08 20:38       ` Linus Björnstam

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).