[m-rev.] diff: clean up typeclass parsing
Mark Brown
mark at cs.mu.OZ.AU
Wed Apr 6 20:06:54 AEST 2005
On 06-Apr-2005, Ralph Becket <rafe at cs.mu.OZ.AU> wrote:
> >
> > Index: compiler/prog_io_typeclass.m
> > ===================================================================
> > +:- type arbitrary_constraint
> > + ---> simple(prog_constraint)
> > + % A class constraint whose arguments are either
> > + % variables or ground terms.
> > +
> > + ; class(prog_constraint)
> > + % An arbitrary class constraint not matching the
> > + % description of "simple".
>
> Wouldn't complex or non_simple be a better name than class?
Yes. I've chosen 'non_simple'.
Cheers,
Mark.
Estimated hours taken: 0.1
Branches: main
compiler/prog_io_typeclass.m:
s/class/non_simple/ in the type arbitrary_constraint, since "class"
is far too general a word.
Index: compiler/prog_io_typeclass.m
===================================================================
RCS file: /home/mercury1/repository/mercury/compiler/prog_io_typeclass.m,v
retrieving revision 1.36
diff -u -r1.36 prog_io_typeclass.m
--- compiler/prog_io_typeclass.m 6 Apr 2005 05:08:04 -0000 1.36
+++ compiler/prog_io_typeclass.m 6 Apr 2005 10:03:08 -0000
@@ -336,7 +336,7 @@
ProgConstraints = [SimpleConstraint | ProgConstraints0],
InstVarSub = InstVarSub0
;
- Constraint = class(ClassConstraint),
+ Constraint = non_simple(ClassConstraint),
ProgConstraints = [ClassConstraint | ProgConstraints0],
InstVarSub = InstVarSub0
;
@@ -350,7 +350,7 @@
% A class constraint whose arguments are either
% variables or ground terms.
- ; class(prog_constraint)
+ ; non_simple(prog_constraint)
% An arbitrary class constraint not matching the
% description of "simple".
@@ -404,7 +404,7 @@
(
constraint_is_not_simple(Constraint)
->
- Result = ok(class(Constraint))
+ Result = ok(non_simple(Constraint))
;
Result = ok(simple(Constraint))
)
--------------------------------------------------------------------------
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