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

Re: MIME for Dylan sourcecode?



>At 1:45 PM -0400 9/3/01, Bruce Hoult wrote:
>I also don't understand the rules for the "define library" and "define
>module" declarations themselves.  Why aren't the "define module"
>declarations nested within the "define library" ones?

They are separate so that you can easily have two libraries which include
the same module.  Say there are two libraries for two different products,
and both use the same utility module.  That utility module could be packaged
in a separate third library which is used by both of the first two.  But
that might increase opportunities for configuration problems, and might
decrease optimization opportunities due to separate compilation of the
product library and the utility library.  Kind of like the choice between
dynamically linking or statically linking a library.  That utility module
could have its module definition copied into the two product libraries, but
that would likely lead to the usual multiple copies of the same 
source code problems, so was not seriously considered as a solution 
to this problem.

The DRM designers didn't spend much time thinking about minimizing number of
source files for an application. We were focused on applications of a
significant size, and mostly assuming some reasonable level of IDE support
for application structuring.  The external text file format was designed to
make it (reasonably) easy to use portable mechanism for moving source code
between development environments. I don't think we game much of any thought
to the notion of a Dylan script written as a single text file.  And I wonder
if that is really the best model for such anyway.  If your favorite Dylan
IDE had an option (possibly even the default) that made setup of most of
the project / module setup needed for a simple script be a 1-button
operation, would you actually care what the external text file format for
the "script" turned out to be?  Of course, that presumes the existance of
an IDE beyond ones favorite text editor and command line compiler.



Follow-Ups: References: