Re: Curry mailing list (welcome)

From: Sergio Antoy <antoy_at_cs.pdx.edu>
Date: Fri, 13 Dec 1996 08:08:23 -0800

I have two comments on the recent proposal, but first of all I'd
like to express my thanks to Michael and Herbert for their work
and for taking the lead.

The first is to some extent a syntactic observation, but I think
that the solution may not be immediate. The second is more
semantic.

------------------------------------------------------------------

A function has (at least) three pieces of information: type,
equations, and evaluation annotations. I think that it would
advantageous to combine them together. This would both keep
textually close concepts that are conceptually close and make
certain errors impossible or easier to detect. As an example and
simplification of what I mean, consider the difference between
Algol60 and Pascal. In Algol (I quote from memory forgive syntax
errors) one declares a procedure and its arguments types and modes
in several steps

        procedure p (x, y);
        int x;
        int y;
        value x;

In Pascal (memory again) one compacts all that into

        procedure p (value int x, int y);

which is definitely preferable. So the question is "Should we try
to provide a construct that allows us to define simultaneously
with the equations also the type and the evaluation annotations
if they are given?"

------------------------------------------------------------------

The restriction on the variables in the right hand side of a
(conditional) equation makes it impossible to define a function f
such as

        f x := y if y = x

which is certainly well-behaved and allowed in many functional
languages. There is some work by Middeldorp and others that
relaxes Curry's restrictions and yet guarantees confluence (the
function is well defined) in situations such as the above example.
We implemented it in our functional extension of Goedel and it was
not very hard. So my question is: "Has this issue been studied
enough or should we study more the issue of the extra variables in
the right hand side of conditional equations?"

I would be happy to work out a new proposal of this issue if
someone sees it fit.

------------------------------------------------------------------

--------------------------------
Sergio Antoy
Dept. of Computer Science
Portland State University
P.O.Box 751
Portland, OR 97207
voice +1 (503) 725-3009
fax +1 (503) 725-3211
internet antoy_at_cs.pdx.edu
WWW http://www.cs.pdx.edu/~antoy
--------------------------------
Received on Mo Dez 16 1996 - 08:38:04 CET

This archive was generated by hypermail 2.3.0 : Do Feb 01 2024 - 07:15:04 CET