[m-rev.] diff: treat foreign types as equivalent to c_pointer

Zoltan Somogyi zs at cs.mu.OZ.AU
Wed May 15 18:42:26 AEST 2002


On 15-May-2002, Fergus Henderson <fjh at cs.mu.OZ.AU> wrote:
> You should not hard-code the name "builtin".
> Instead, you should use `mercury_public_builtin_module'.
> Also, it would be simpler if you use `construct_type':
> 
> 	mercury_public_builtin_module(Builtin),
> 	construct_type(qualified(Builtin, "c_pointer") - 0, [], Type)

Actually, even that is too verbose.

	Type = c_pointer_type

is sufficient. There is such a function for pretty much all the builtin types
the compiler handles specially in type_util.m.

Zoltan.
--------------------------------------------------------------------------
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