[Top][All Lists]

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

Re: [Chicken-hackers] [PATCH] Fix #1133

From: Peter Bex
Subject: Re: [Chicken-hackers] [PATCH] Fix #1133
Date: Thu, 19 Jun 2014 21:27:37 +0200
User-agent: Mutt/

On Thu, Jun 19, 2014 at 09:13:01PM +0200, Felix Winkelmann wrote:
> A few remarks:

Hi Felix,

Thanks for replying!

> - Modules are a namespace-specific concept, units are a
>   loading/linking concept. Are you really comparing these here?

Well, kind of.  Let me tip-toe around the definitions to clarify:
Currently units are used in core to define dependencies, which is one
of the things that modules are used for as well. And as we saw in
this ticket and the other one there are some problems which can be
detected in dependencies expressed as modules but not when using
"just units".

> - The possibility of static linking needs to be preserved.

I agree completely, and said as much in my email.

> - The module system is currently optional - one can just use core
>   procedures in a toplevel program without using modules at all.  The
>   machinery to make this work is admittedly ugly, but still I consider
>   it a feature. Forcing pervasive use of modules is noit by itself a
>   bad thing, but need to be thought out thoroughly.

Yes, this is a concern.  I think it may be possible to hook the unit
system into the module system somehow (or vice versa), but you're right
in that this won't "just work".

> - It's possible that I misunderstand your intentions, considering the
>   many meanings of the word "module" used in this context. But another
>   issue that comes to mind is bootstrapping: if you change the
>   imports/exports of a module that represents a core library unit, how
>   can we prevent screw-ups due to mixing up of the
>   import/export-information (import libraries) between the chicken
>   that compiles and the chicken that is compiled? This can get very
>   tricky.

Indeed, bootstrapping is an ever-present pitfall.  And there's also
library.scm which does not really correspond to a particular module.
Perhaps to "scheme", but not exactly.

I just wanted to put the idea out there, as a sort of "call to arms".
This is another large-scale project that will take a lot of energy which
I personally don't have right now.  Maybe I'll put it on the wish-list
for a long-term goal.


reply via email to

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