Re: Confused Students

From: <kahl_at_cas.mcmaster.ca>
Date: Tue, 19 Jun 2007 22:40:15 +0000

> This is similar and related to the
> following: u = x?y implies f u = f (x?y) holds for term rewriting,
> but not for Curry programs. Here is an example:
>
> test = (not u, not u)
> where u = x?y
> x = True
> y = False

What is ``f'' in this example?

The other question is of course the precise meaning of ``=''...


The thing that does definitely not hold in Curry is substitution of equals:

u = x?y does not imply t[v \ u] = t[v \ (x?y)].


But even if you set

test v = (not v, not v)
u = x ? y

, you still have

test u = test (x?y)

(at least in my understanding of Curry).


Wolfram
_______________________________________________
curry mailing list
curry_at_lists.RWTH-Aachen.DE
http://MailMan.RWTH-Aachen.DE/mailman/listinfo/curry
Received on Mi Jun 20 2007 - 08:56:31 CEST

This archive was generated by hypermail 2.3.0 : Do Jun 20 2024 - 07:15:09 CEST