[m-dev.] Changes to runtime.
fjh at cs.mu.oz.au
Mon Sep 15 16:10:39 AEST 1997
Tyson Richard DOWD, you wrote:
> In order to add layout information about stack frames, every entry label
> needs to have a stack_layout structure defined for it, and every
> internal label needs a similar structure which refers to the entry
> To do this in the .mod files in the runtime, it is simplest to just
> stop using .mod files altogether, and instead use .c files.
That's fine with me.
> At the same time, I could pretty easily rename those .c files
> to mercury_whatever.c.
Let me take a second to explain the naming policy and its rationale.
- header file names should contain a unique prefix such as
`mercury_' (or perhaps `mercury/' -- but that has other
difficulties). The reason for this is to avoid name clashes
with header files defined in other packages.
- If the header file for a module is named `foo.h', then
then C file should be named `foo.c'. The reason for this
is to make it clear that they belong together.
So, renaming the whatever.c files to mercury_whatever.c is desirable
if and only if you also rename the whatever.h files to mercury_whatever.h.
Fergus Henderson <fjh at cs.mu.oz.au> | "I have always known that the pursuit
WWW: <http://www.cs.mu.oz.au/~fjh> | of excellence is a lethal habit"
PGP: finger fjh at 184.108.40.206 | -- the last words of T. S. Garp.
More information about the developers