guile-devel
[Top][All Lists]
Advanced

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

Re: (define-module (foo) #:import (...)), a la r6rs


From: Ludovic Courtès
Subject: Re: (define-module (foo) #:import (...)), a la r6rs
Date: Thu, 10 Nov 2011 00:50:10 +0100
User-agent: Gnus/5.110018 (No Gnus v0.18) Emacs/24.0.90 (gnu/linux)

Hi!

Andy Wingo <address@hidden> skribis:

> On Thu 28 Jul 2011 23:23, address@hidden (Ludovic Courtès) writes:
>
>> Andy Wingo <address@hidden> skribis:
>>
>>> So what do you all think about:
>>>
>>>   (define-module (foo)
>>>     #:import ((bar)
>>>               (only (baz) qux foo)
>>>               ...))
>>>
>>> Or even:
>>>
>>>   (define-module (foo)
>>>     (import (bar)
>>>             (only (baz) qux foo)
>>>             ...))
>>
>> I’d prefer #:use-modules (plural), for consistency:
>>
>>   (define-module (foo)
>>     #:use-modules ((bar)
>>                    (baz) #:select (qux foo)
>>                    (chbouib) #:renamer (symbol-prefix-proc 'p)))
>>
>> What do you think?
>
> I don't like the paren placement so much.  Consistency is important, but
> TBH I think that we should phase out the "use-module" / "use-modules"
> terminology, in favor of "import" terminology of r6rs and the coming
> r7rs.
>
> What do you think about that? :-)

I find aesthetics important, but phasing out such an important construct
“just” for aesthetics seems harsh to me.

Besides, stuff like #:renamer is strictly more powerful than what
R[67]RS provide, IIRC.

Actually I’m happy with the ways things are currently, so I’m obviously
biased.  ;-)

Thanks,
Ludo’.



reply via email to

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