[m-rev.] for review: pragma foreign_import_module on the IL backend

Fergus Henderson fjh at cs.mu.OZ.AU
Thu Dec 12 03:10:41 AEDT 2002


On 11-Dec-2002, Peter Ross <pro at missioncriticalit.com> wrote:
> fjh wrote:
> > On 10-Dec-2002, Peter Ross <pro at missioncriticalit.com> wrote:
> > > compiler/ml_code_gen.m:
> > > The wanted foreign imports are the imports for every backend
> > > language.  This is because, for example, managed C++ can refer
> > > to something defined in IL.
> > >
> > > compiler/mlds_to_managed.m:
> > > For managed C++ output a #using for every module implied by the
> > > pragma foreign_import_module.
> >
> > Hmm.  What about cyclic imports?
>
> Cyclic imports are a problem for the .NET implementations.

Only for C# and MC++, not for IL or Mercury -- right?

If Mercury's foreign_import_module declaration does not permit cyclic
imports for C# or MC++ code, this should be mentioned in the Mercury
language reference manual.

> This is a
> general problem with using assemblies to hold both the interface and the
> implementation.  The programmer must ensure that they don't introduce a
> cyclic dependency.  Note that mmake will report a cyclic dependency warning
> and that combined with the failure to build a file because of a missing
> assembly should be enough for the programmer to debug the problem.

What happens with `mmc --make'?
Will the user still get a warning about the cyclic dependency in that case?

-- 
Fergus Henderson <fjh at cs.mu.oz.au>  |  "I have always known that the pursuit
The University of Melbourne         |  of excellence is a lethal habit"
WWW: <http://www.cs.mu.oz.au/~fjh>  |     -- the last words of T. S. Garp.
--------------------------------------------------------------------------
mercury-reviews mailing list
post:  mercury-reviews at cs.mu.oz.au
administrative address: owner-mercury-reviews at cs.mu.oz.au
unsubscribe: Address: mercury-reviews-request at cs.mu.oz.au Message: unsubscribe
subscribe:   Address: mercury-reviews-request at cs.mu.oz.au Message: subscribe
--------------------------------------------------------------------------



More information about the reviews mailing list