[m-dev.] for review: add Mission Critical extensions
Simon Taylor
stayl at cs.mu.OZ.AU
Thu Jul 6 11:59:54 AEST 2000
This is not a full review. I've only reviewed the comments, not the code.
> Estimated hours taken: 16
>
> Add the Mission Critical extensions to the compiler. These extensions
> are only turned on if --enable-mc is supplied to configure.
> The point of this change is to minimize the diff between the Mission
> Critical Mercury compiler and the Melbourne Mercury compiler.
Please add something here to explain why the Mission Critical version
of the compiler needs to be different, and why these features can't be
enabled by default.
> configure.in:
> Add --enable-mc to configure. This options turns on the Mission
> Critical extensions to the compiler.
The option name should describe the feature being enabled, rather
than the user of that feature. `--enable-mc' is also a bad name for
this option because until Mercury 0.7 `mc' was the name of the
Melbourne Mercury Compiler.
> runtime/mercury_conf.h.in:
> Add MR_MISCRIT_EXTS which is defined when --enable-mc is passed to
> configure.
>
> runtime/mercury_conf_param.h:
> If we are using the Mission Critical extensions, define
> MISCRIT_STREAMS.
The names of these #defines should describe the features, rather
than who uses them.
> runtime/mercury_library_types.h:
> If MISCRIT_STREAMS is defined use the Mission Critical version of
> the type MercuryFile. The new definition of MercuryFile makes it
> possible for Mercury to handle streams connected to sockets and
> pipes under WinNT. The MercuryFile structure now contains pointers
> to functions to do the basic operations on streams, which allows
> them to be changed according to the type of stream.
> All this extra functionality is then hidden behind macros,
> allowing the original definition of MercuryFile to coexist.
Isn't this useful for users other than Mission Critical?
> library/exception.m:
> Export the modes of try/2 and try_io/4 that take det predicates as C
> functions. This allows Mission Critical to change the semantics of
> these two calls, in their own libraries.
To do what? Why can't these `:- pragma export' declarations be placed
in Mission Critical's libraries?
> Index: runtime/mercury_conf.h.in
> ===================================================================
> +
> +/*
> +** MR_MISCRIT_EXTS
> +** Set this if you want to use the Mission Critical version of the
> +** compiler.
> +*/
> +#undef MR_MISCRIT_EXTS
Again, this needs more documentation about the extensions.
Simon.
--------------------------------------------------------------------------
mercury-developers mailing list
Post messages to: mercury-developers at cs.mu.oz.au
Administrative Queries: owner-mercury-developers at cs.mu.oz.au
Subscriptions: mercury-developers-request at cs.mu.oz.au
--------------------------------------------------------------------------
More information about the developers
mailing list