Re: New PAKCS release (Version 1.8.0)

From: Emilio Jesús Gallego Arias <egallego_at_babel.ls.fi.upm.es>
Date: Fri, 30 Mar 2007 15:16:16 +0200

Wolfgang Lux <wlux_at_uni-muenster.de> writes:

> Emilio Jesús Gallego Arias wrote:
>
>> WRT Sloth operational behavior, what it does is simple common
>> expression elimination, so for the coin case you get
>>
>> (coin,coin) is transformed to let M = coin in (M, M)
>
> I see. However, the above transformation is not valid in Curry --
> at least in the general case. Just replace coin in the definition
> above by the Prelude function
> unknown = x where x free
>
> Now, for (unknown,unknown) you get to distinct variables, whereas
> for let M = unknown in (M,M) you get only one.

Yes, this transformation is not valid Curry, (and our hack does
it).

It's likely that in this setting free variables should be empowered
with some kind of abstract syntax operators to define its true scope.

>> coin = [0,1]
>>
>> so then, in any sane semantics (both operational or denotational) the
>> equation
>>
>> let x = coin in (x,x) == (coin,coin)
>>
>> does hold. This is the kind of treatment I'd like to have. I'm
>> sorry I haven't fully developed it yet.
>
> You could perform determinism analysis in order to apply your
> transformation iff the expressions involved are determinstic.

Yes, that is a good idea, however I'm hoping we can avoid it, if we
lift all non-deterministic programs to the list monad, for
instance. (As every program becomes deterministic)

Thanks,

Emilio


_______________________________________________
curry mailing list
curry_at_lists.RWTH-Aachen.DE
http://MailMan.RWTH-Aachen.DE/mailman/listinfo/curry
Received on Mi Apr 11 2007 - 11:56:08 CEST

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