guile-user
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: define anywhere


From: Linus Björnstam
Subject: Re: define anywhere
Date: Sun, 06 Jun 2021 15:36:28 +0200
User-agent: Cyrus-JMAP/3.5.0-alpha0-519-g27a961944e-fm-20210531.001-g27a96194

Oh, my version is an error. I implemented the macro before definitions in 
(some) expression contexts were a thing.

Andy did a marvellous thing implementinf the new letrec: if it is possible, 
letrec will have no overhead. It also automatically handle dependant clauses: 
even though it might seem counterintuitive, the guile-proper version will do 
the right thing always. The syntactic differentiation mine does is just there 
for our feeble human minds, at least with regards to what guile-proper is doing.

So TL/DR: guiles way is the correct way. 

-- 
  Linus Björnstam

On Sun, 6 Jun 2021, at 14:02, Dr. Arne Babenhauserheide wrote:
> 
> Linus Björnstam <linus.internet@fastmail.se> writes:
> 
> > becomes ONE letrec under gulie3, whereas my library turns it into
> > (letrec ((a 2) (b 3))
> >   (display "hej")
> >   (letrec ((c 3))
> >     (+ a b c)))
> >
> > That should be an easy fix, again if there is any interest.
> 
> I’m not sure which approach I prefer. Your approach is more precise, but
> I slightly lean towards the Guile3-version, because it does not change
> behaviour when I put a pretty-print between two defines.
> 
> Though I would want a precise approach inside other forms (like when:
> separating inside when and outside when).
> 
> Best wishes,
> Arne
> -- 
> Unpolitisch sein
> heißt politisch sein
> ohne es zu merken
> 
> Attachments:
> * signature.asc



reply via email to

[Prev in Thread] Current Thread [Next in Thread]