[m-rev.] diff: fix some incorrect promise_pures in benchmarking.m

Ian MacLarty maclarty at csse.unimelb.edu.au
Mon Apr 14 12:19:58 AEST 2008


Estimated hours taken: 0.2
Branches: main

library/benchmarking.m:
	Fix some incorrect promise_pure scopes.

Index: library/benchmarking.m
===================================================================
RCS file: /home/mercury1/repository/mercury/library/benchmarking.m,v
retrieving revision 1.79
diff -u -r1.79 benchmarking.m
--- library/benchmarking.m	18 Mar 2008 03:09:43 -0000	1.79
+++ library/benchmarking.m	13 Apr 2008 03:37:14 -0000
@@ -1023,11 +1023,15 @@
 %-----------------------------------------------------------------------------%
 %-----------------------------------------------------------------------------%
 
+:- pragma promise_pure(turn_off_profiling/2).
+
 turn_off_profiling(!IO) :-
-    promise_pure ( impure turn_off_profiling ).
+    impure turn_off_profiling.
+
+:- pragma promise_pure(turn_on_profiling/2).
 
 turn_on_profiling(!IO) :-
-    promise_pure ( impure turn_on_profiling ).
+    impure turn_on_profiling.
 
 turn_off_profiling :-
     impure turn_off_call_profiling,
@@ -1041,23 +1045,35 @@
 
 %-----------------------------------------------------------------------------%
 
+:- pragma promise_pure(turn_off_call_profiling/2).
+
 turn_off_call_profiling(!IO) :-
-    promise_pure ( impure turn_off_call_profiling ).
+    impure turn_off_call_profiling.
+
+:- pragma promise_pure(turn_on_call_profiling/2).
 
 turn_on_call_profiling(!IO) :-
-    promise_pure ( impure turn_on_call_profiling ).
+    impure turn_on_call_profiling.
+
+:- pragma promise_pure(turn_off_time_profiling/2).
 
 turn_off_time_profiling(!IO) :-
-    promise_pure ( impure turn_off_time_profiling ).
+    impure turn_off_time_profiling.
+
+:- pragma promise_pure(turn_on_time_profiling/2).
 
 turn_on_time_profiling(!IO) :-
-    promise_pure ( impure turn_on_time_profiling ).
+    impure turn_on_time_profiling.
+
+:- pragma promise_pure(turn_off_heap_profiling/2).
 
 turn_off_heap_profiling(!IO) :-
-    promise_pure ( impure turn_off_heap_profiling ).
+    impure turn_off_heap_profiling.
+
+:- pragma promise_pure(turn_on_heap_profiling/2).
 
 turn_on_heap_profiling(!IO) :-
-    promise_pure ( impure turn_on_heap_profiling ).
+    impure turn_on_heap_profiling.
 
 %-----------------------------------------------------------------------------%
 
--------------------------------------------------------------------------
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