[m-rev.] diff: add cc_multi modes for map.foldl and map.foldr

Ian MacLarty maclarty at csse.unimelb.edu.au
Mon Feb 16 10:49:49 AEDT 2009


Estimated time taken: 0.1
Branches: main

Add cc_multi modes for map.foldl and map.foldr.

library/map.m:
library/tree234.m:
	Add cc_multi modes for foldl and foldr.

Index: library/map.m
===================================================================
RCS file: /home/mercury1/repository/mercury/library/map.m,v
retrieving revision 1.113
diff -u -r1.113 map.m
--- library/map.m	2 Jan 2009 03:12:08 -0000	1.113
+++ library/map.m	15 Feb 2009 23:22:55 -0000
@@ -303,6 +303,8 @@
 :- mode map.foldl(pred(in, in, in, out) is semidet, in, in, out) is semidet.
 :- mode map.foldl(pred(in, in, mdi, muo) is semidet, in, mdi, muo) is semidet.
 :- mode map.foldl(pred(in, in, di, uo) is semidet, in, di, uo) is semidet.
+:- mode map.foldl(pred(in, in, in, out) is cc_multi, in, in, out) is cc_multi.
+:- mode map.foldl(pred(in, in, di, uo) is cc_multi, in, di, uo) is cc_multi.
 
 :- func map.foldr(func(K, V, A) = A, map(K, V), A) = A.
 :- pred map.foldr(pred(K, V, A, A), map(K, V), A, A).
@@ -312,6 +314,8 @@
 :- mode map.foldr(pred(in, in, in, out) is semidet, in, in, out) is semidet.
 :- mode map.foldr(pred(in, in, mdi, muo) is semidet, in, mdi, muo) is semidet.
 :- mode map.foldr(pred(in, in, di, uo) is semidet, in, di, uo) is semidet.
+:- mode map.foldr(pred(in, in, in, out) is cc_multi, in, in, out) is cc_multi.
+:- mode map.foldr(pred(in, in, di, uo) is cc_multi, in, di, uo) is cc_multi.
 
     % Perform an inorder traversal of the map, applying an accumulator
     % predicate with two accumulators for each key-value pair.
Index: library/tree234.m
===================================================================
RCS file: /home/mercury1/repository/mercury/library/tree234.m,v
retrieving revision 1.63
diff -u -r1.63 tree234.m
--- library/tree234.m	2 Jan 2009 03:12:08 -0000	1.63
+++ library/tree234.m	15 Feb 2009 23:24:55 -0000
@@ -136,6 +136,10 @@
     is semidet.
 :- mode tree234.foldl(pred(in, in, di, uo) is semidet, in, di, uo)
     is semidet.
+:- mode tree234.foldl(pred(in, in, in, out) is cc_multi, in, in, out)
+    is cc_multi.
+:- mode tree234.foldl(pred(in, in, di, uo) is cc_multi, in, di, uo)
+    is cc_multi.
 
 :- pred tree234.foldl2(pred(K, V, A, A, B, B), tree234(K, V), A, A, B, B).
 :- mode tree234.foldl2(pred(in, in, in, out, in, out) is det,
@@ -195,6 +199,10 @@
     is semidet.
 :- mode tree234.foldr(pred(in, in, di, uo) is semidet, in, di, uo)
     is semidet.
+:- mode tree234.foldr(pred(in, in, in, out) is cc_multi, in, in, out)
+    is cc_multi.
+:- mode tree234.foldr(pred(in, in, di, uo) is cc_multi, in, di, uo)
+    is cc_multi.
 
 :- pred tree234.foldr2(pred(K, V, A, A, B, B), tree234(K, V), A, A, B, B).
 :- mode tree234.foldr2(pred(in, in, in, out, in, out) is det,
--------------------------------------------------------------------------
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