guile-devel
[Top][All Lists]
Advanced

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

Re: Re-exporting a replaced binding


From: Ludovic Courtès
Subject: Re: Re-exporting a replaced binding
Date: Mon, 06 Jan 2020 10:54:43 +0100
User-agent: Gnus/5.13 (Gnus v5.13) Emacs/26.3 (gnu/linux)

Hi!

Andy Wingo <address@hidden> skribis:

> On Fri 03 Jan 2020 19:30, Ludovic Courtès <address@hidden> writes:

[...]

>> Should the #:re-export clause propagate the replace bit, or should
>> it not?  :-)
>
> It is a good question :)  Before, if you re-exported a #:replace
> binding, it wasn't possible to have it be exported without the "replace"
> bit set.  After the change it is possible to do either, and the default
> changes to not replacing.  From NEWS:
>
>   Note to make this change, we had to change the way replacement flags
>   are stored, to being associated with modules instead of individual
>   variable objects.  This means that users who #:re-export an imported
>   binding that was already marked as #:replace by another module will
>   now see warnings, as they need to use #:re-export-and-replace instead.
>
> The 3.0 behavior differs from 2.2 in this regard, although it's just
> warnings and not run-time behavior.  I am sympathetic to the concern
> that it can be difficult to make a system that warns/doesn't warn in the
> same way on 2.2 vs 3.0 but I think the change is the right thing, as the
> new behavior is more expressive.  Because it's a user-visible change it
> is in NEWS.  LMK if you think we need a change here!

I agree that the new mechanism is more expressive, I guess I just hadn’t
realized how it affects re-exports of already-exported bindings.  It’s
easily addressed anyway.

Thank you!

Ludo’.



reply via email to

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