[m-rev.] diff: implement array unifications.
Tyson Dowd
trd at miscrit.be
Thu Sep 20 22:42:35 AEST 2001
Hi,
Much easier than I thought it would be...
===================================================================
Estimated hours taken: 0.5
Branches: main
library/array.m:
Implement array unifications.
Index: library/array.m
===================================================================
RCS file: /home/mercury1/repository/mercury/library/array.m,v
retrieving revision 1.99
diff -u -r1.99 array.m
--- library/array.m 5 Sep 2001 08:16:04 -0000 1.99
+++ library/array.m 20 Sep 2001 10:23:27 -0000
@@ -611,15 +611,16 @@
static int
special___Unify___array_1_0(MR_Word type_info, MR_Array x, MR_Array y)
{
- mercury::runtime::Errors::SORRY(""unify for array"");
- return 0;
+ return mercury::array::mercury_code::ML_array_equal(
+ type_info, x, y);
}
static void
special___Compare___array_1_0(
MR_Word type_info, MR_Word_Ref result, MR_Array x, MR_Array y)
{
- mercury::runtime::Errors::SORRY(""compare for array"");
+ mercury::array::mercury_code::ML_array_compare(
+ type_info, result, x, y);
}
static int
@@ -644,6 +645,10 @@
%-----------------------------------------------------------------------------%
+
+
+:- pragma export(array_equal(in, in), "ML_array_equal").
+:- pragma export(array_compare(out, in, in), "ML_array_compare").
% unify/2 for arrays
--------------------------------------------------------------------------
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