From: Stephan Houben <stephan@pcrm.win.tue.nl>
To: caml-list@inria.fr
Subject: Re: Why does the order in the Makefile matter?
Date: Wed, 1 Nov 2000 08:38:39 +0100 [thread overview]
Message-ID: <00110108462300.08310@pcrm> (raw)
In-Reply-To: <200010281655.SAA31819@pauillac.inria.fr>
On Sat, 28 Oct 2000, Pierre Weis wrote:
> Hence, when the entire program is made of multiple implementation
> files, those files must be linked in any order that is compatible with
> the static binding rule: no definition can be linked if it refers to
> an identifier that is defined after the definition at hand. In
> addition, expressions to be computed must evidently appear in any
> order compatible with the desired runtime behaviour.
I completely understand this point, and I agree that there are legal
Caml programs that have a different behavior depending on the order
of the .cmo file linking. However, every program I write (and I suppose
that's true for most of us) has an invariant behavior under all legal
permutations of the .cmo files. Mostly because I only have 1 .ml file
that actually does anything; the rest only contain side-effect-free
definitions.
So it would be nice if the compiler itself could put the .cmo files in an order
compatible with the static binding rule. This would remove the tedium of
putting the .cmo files in an appropriate order from the programmer.
Would this be difficult to implement?
Perhaps this could be made a compiler switch?
Stephan
--
ir. Stephan H.M.J. Houben
tel. +31-40-2474358 / +31-40-2743497
e-mail: stephanh@win.tue.nl
next prev parent reply other threads:[~2000-11-02 17:53 UTC|newest]
Thread overview: 7+ messages / expand[flat|nested] mbox.gz Atom feed top
2000-10-28 8:01 Mattias Waldau
2000-10-28 16:55 ` Pierre Weis
2000-10-30 8:30 ` Why does the order in the Makefile matter? --- Linking with C kahl
2000-10-31 7:39 ` Why does the order in the Makefile matter? Mattias Waldau
2000-11-01 7:38 ` Stephan Houben [this message]
2000-11-02 18:22 ` Pierre Weis
2000-11-03 7:24 ` Judicael Courant
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=00110108462300.08310@pcrm \
--to=stephan@pcrm.win.tue.nl \
--cc=caml-list@inria.fr \
--cc=stephanh@win.tue.nl \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox