[m-rev.] diff: fix bugs in smart recompilation

Simon Taylor stayl at cs.mu.OZ.AU
Wed Jul 25 03:37:49 AEST 2001


On 24-Jul-2001, Fergus Henderson <fjh at cs.mu.OZ.AU> wrote:
> On 24-Jul-2001, Simon Taylor <stayl at cs.mu.OZ.AU> wrote:
> > 
> > +:- func item_is_unchanged(item, item) = bool.
> > +
> > +	% We don't need to compare the varsets. What matters is that
> > +	% the variable numbers in the arguments and body are the same,
> > +	% the names are irrelevant.
> 
> Hmm, that looks wrong to me.  Maybe you're not aware of the following sentence
> from the Mercury language reference manual:
> 
>  | The scope of type variables in a predicate or function's type
>  | declaration extends over any explicit type qualifications in the
>  | clauses for that predicate or function, so explicit type qualifications
>  | can refer to those type variables.


Estimated hours taken: 0.2
Branches: main, release

doc/reference_manual.texi:
	Fix the documentation of variable scoping.
	The scope of type variables in a predicate or
	function declaration extends over any
	`:- pragma type_spec' declarations for
	that predicate or function.

Index: reference_manual.texi
===================================================================
RCS file: /home/mercury1/repository/mercury/doc/reference_manual.texi,v
retrieving revision 1.210
diff -u -u -r1.210 reference_manual.texi
--- reference_manual.texi	2001/07/23 16:53:01	1.210
+++ reference_manual.texi	2001/07/24 17:36:25
@@ -1177,12 +1177,15 @@
 (@pxref{Goals}) or implicitly (@pxref{Implicit quantification}).
 
 The scope of type variables in a predicate or function's type
-declaration extends over any explicit type qualifications in the
-clauses for that predicate or function, so explicit type
-qualifications can refer to those type variables.
-The scope of any type variables in an explicit type qualification
-which do not occur in the predicate or function's type declaration
-is the clause in which they occur.
+declaration extends over any explicit type qualifications
+(@pxref{Explicit type qualification}) in the clauses for that
+predicate or function, and over @samp{pragma type_spec}
+(@pxref{Type specialization}) declarations for that predicate or
+function, so that explicit type qualifications and
+ at samp{pragma type_spec} declarations can refer to those
+type variables. The scope of any type variables in an explicit
+type qualification which do not occur in the predicate or function's
+type declaration is the clause in which they occur.
 
 @node Implicit quantification
 @section Implicit quantification
--------------------------------------------------------------------------
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