[m-rev.] diff: get library compiling in ilc grade

Peter Ross peter.ross at miscrit.be
Wed Feb 6 16:54:57 AEDT 2002


A minor fix for a problem pointed out by Michael.

===================================================================


Estimated hours taken: 0.1
Branches: main

library/type_desc.m:
    Remove promise_pure declarations from the make_type foreign_proc
    declarations so that the pragma promise_pure isn't redundant.  The
    pragma version is needed on non C backends.

Index: type_desc.m
===================================================================
RCS file: /home/mercury1/repository/mercury/library/type_desc.m,v
retrieving revision 1.2
diff -u -r1.2 type_desc.m
--- type_desc.m	5 Feb 2002 16:30:07 -0000	1.2
+++ type_desc.m	6 Feb 2002 05:49:57 -0000
@@ -555,9 +555,10 @@
 	** a new type with the specified arguments.
 	*/
 
+:- pragma promise_pure(make_type/2).
 :- pragma foreign_proc("C", 
 	make_type(TypeCtorDesc::in, ArgTypes::in) = (TypeDesc::out),
-	[will_not_call_mercury, thread_safe, promise_pure],
+	[will_not_call_mercury, thread_safe],
 "{
 	MR_TypeCtorDesc type_ctor_desc;
 	MR_TypeCtorInfo type_ctor_info;
@@ -591,7 +592,6 @@
 	}
 }").
 
-:- pragma promise_pure(make_type/2).
 make_type(_TypeCtorDesc::in, _ArgTypes::in) = (_TypeDesc::out) :-
 	private_builtin__sorry("make_type/2 forward mode.").
 
@@ -603,7 +603,7 @@
 
 :- pragma foreign_proc("C", 
 	make_type(TypeCtorDesc::out, ArgTypes::out) = (TypeDesc::in),
-	[will_not_call_mercury, thread_safe, promise_pure],
+	[will_not_call_mercury, thread_safe],
 "{
 	MR_TypeCtorDesc type_ctor_desc;
 	MR_TypeInfo	type_info;

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