chicken-hackers
[Top][All Lists]
Advanced

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

Re: [Chicken-hackers] [PATCH] Add unexport form for modules


From: Jörg F . Wittenberger
Subject: Re: [Chicken-hackers] [PATCH] Add unexport form for modules
Date: 04 Jul 2017 21:48:33 +0200

I agree that an explicit export list is beneficial for polished code.

However I do often use modules for *import* control, a.k.a. catching my typos, rather than export control. That's when the *-export is very useful.

/Jörg

On Jul 4 2017, megane wrote:


John Cowan <address@hidden> writes:

On Tue, Jul 4, 2017 at 10:11 AM, megane <address@hidden> wrote:

Working with the export list is painful without some syntax support. You
end up repeating every identifier name otherwise.


I consider the repetition to be a virtue rather than a vice.

The whole purpose of modules is to control what identifiers are exposed to the outside world and what identifiers are private. If you want to expose everything, why bother with a module at all? Just have a plain file that is included rather than imported.

I, too, want to precisely control what a module exports and what it
doesn't.

I think keeping the * export would be nice for beginners coming from
languages where export control is less manual work. I myself don't care
anymore.
...




reply via email to

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