[m-dev.] for review: prog_io_typeclass.m ROTD; 2 of 5
doug.auclair at logicaltypes.com
doug.auclair at logicaltypes.com
Fri Feb 17 18:57:44 AEDT 2006
Dear all,
Here are the diffs for prog_io_typeclass.m in the ROTD (2006-02-11) to implement op/3.
Sincerely,
Doug Auclair
--- prog_io_typeclass.m.~1.48.~ 2006-01-15 22:08:14.000000000 -0500
+++ prog_io_typeclass.m 2006-02-16 22:21:45.000000000 -0500
@@ -67,6 +67,7 @@
:- import_module string.
:- import_module term.
:- import_module varset.
+:- import_module ops.
parse_typeclass(ModuleName, VarSet, TypeClassTerm, Result) :-
% XXX We should return an error if we get more than one arg, instead of
@@ -252,7 +253,8 @@
->
list__map((pred(MethodTerm::in, Method::out) is det :-
% Turn the term into an item.
- parse_decl(ModuleName, VarSet, MethodTerm, Item),
+ init_mercury_op_map(init_mercury_op_table, OpMap),
+ parse_decl(ModuleName, VarSet, MethodTerm, Item, OpMap, _),
% Turn the item into a class_method.
item_to_class_method(Item, MethodTerm, Method)
), MethodList, Interface),
@@ -759,7 +761,8 @@
% qualifiers in the clauses don't match the module name of the class,
% we will pick that up later, in check_typeclass.m.)
DefaultModuleName = unqualified(""),
- parse_item(DefaultModuleName, VarSet, MethodTerm, Result0),
+ init_mercury_op_map(init_mercury_op_table, OpMap),
+ parse_item(DefaultModuleName, VarSet, MethodTerm, Result0, OpMap, _),
(
Result0 = ok(Item, Context),
Item = clause(_Origin, _VarNames, PredOrFunc, ClassMethodName,
--------------------------------------------------------------------------
mercury-developers mailing list
Post messages to: mercury-developers at cs.mu.oz.au
Administrative Queries: owner-mercury-developers at cs.mu.oz.au
Subscriptions: mercury-developers-request at cs.mu.oz.au
--------------------------------------------------------------------------
More information about the developers
mailing list