[m-rev.] for review: io.write for streams

Simon Taylor staylr at gmail.com
Thu Dec 21 01:15:13 AEDT 2006


On 21-Dec-2006, Julien Fischer <juliensf at csse.unimelb.edu.au> wrote:
> I don't like the idea of a sub-module having the same (unqualified) name as
> another standard library module.  Neither does the compiler apparently (see
> below **).
> 
> You might as well go with stream.string_writer; none of the alternatives
> have been particularly appealing.

OK.
 
> ** the following is a bug, presumably in the code that generates
>    the dependencies, although I haven't looked that closely.
> 
> 	:- module foo.
> 	:- interface.
> 	:- include_module foo.
> 	:- end_module foo.
> 
> 	:- module foo.char.
> 	:- interface.
> 	:- pred bar(int::in) is semidet.
> 	:- implementation.
> 	bar(561).
> 	:- end_module foo.char.
> 
> mmc --make foo or mmake foo.depend both go into a loop with the
> above modules.

This fails because of the `:- include_module foo'.
The compiler is quite happy with a sub-module `char'.

Simon.
--------------------------------------------------------------------------
mercury-reviews mailing list
Post messages to:       mercury-reviews at csse.unimelb.edu.au
Administrative Queries: owner-mercury-reviews at csse.unimelb.edu.au
Subscriptions:          mercury-reviews-request at csse.unimelb.edu.au
--------------------------------------------------------------------------



More information about the reviews mailing list