[m-dev.] for review: pragma foreign_code for MC++ (part 2/2)

Tyson Dowd trd at cs.mu.OZ.AU
Thu Nov 16 11:45:20 AEDT 2000


> > --- tests/invalid/pragma_c_code_and_clauses1.err_exp	1998/02/02 03:01:11	1.3
> > +++ tests/invalid/pragma_c_code_and_clauses1.err_exp	2000/11/09 00:58:23
> > @@ -1,6 +1,6 @@
> >  pragma_c_code_and_clauses1.m:009: Warning: `pragma' declaration in module interface.
> >  pragma_c_code_and_clauses1.m:007: Warning: clause in module interface.
> > -pragma_c_code_and_clauses1.m:009: Error: `:- pragma c_code' declaration for predicate `pragma_c_code_and_clauses1:foo/1'
> > +pragma_c_code_and_clauses1.m:009: Error: `:- pragma foreign_code' declaration for predicate `pragma_c_code_and_clauses1:foo/1'
> 
> The updated error messages are misleading, since there's no
> `pragma foreign_code' in the test case's source code.
> 
> This could be fixed by keeping track of the syntax used in
> the original declaration.

This is quite a bit of trouble -- I don't mind doing it, but I'd prefer
to wait until I have a high bandwidth conection to do it.

> Alternatively, the error messages could be changed so that they all
> say "`pragma foreign_code' (or `pragma c_code')".

I'll do this for now, which is a bit uglier, but should at least avoid
the confusion for now.

> Apart from that, this change looks fine.
> As usual I'd like to see a relative diff for any new changes.

Working on it.

-- 
       Tyson Dowd           # 
                            #  Surreal humour isn't everyone's cup of fur.
     trd at cs.mu.oz.au        # 
http://www.cs.mu.oz.au/~trd #
--------------------------------------------------------------------------
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