Re: PAKCS Internal Functions

From: Michael Hanus <mh_at_informatik.uni-kiel.de>
Date: Sat, 16 May 2015 17:40:06 +0200

Hi Andy,

since Sergio already answered your questions, I only add some comments.

On 05/14/2015 11:58 PM, h7sa_at_pdx.edu wrote:
> > I can't find any difference in behavior between these, however. In what sense is =:<= non-strict? I thought perhaps this expression would succeed:
> >
> > cond ([1 `div` 0] =:<= x) (length x) where x free
> >
> > But it gives a zero_divisor error. Can anyone provide an example that illustrates the difference between these?
>
> With PAKCS 1.11.4 (4), SICSTUS 3.7, on my laptop, I get:
>
> Prelude> cond ([1 `div` 0] =:<= x) (length x) where x free
> SICStus 3.7.1 (Linux-2.2.5-15-i686): Wed Aug 11 16:30:39 CEST 1999
> Licensed to cat.pdx.edu
> {x=[0]} 1
> Prelude>
>
> This is not entirely expected ;)

Right, this is not expected. It must be related to the SICStus Version,
since I get a division-by-zero error with SICStus 4.3.

As Sergio already wrote, the operations (=:<<=) and ifVar do not occur
or are generated in standard Curry programs, but they are internally
used. Hence, there is no need to implement them. In particular, ifVar
is used during the evaluation of (=:<=) to check multiple occurrences
of pattern variables in order to generate strict equalities between
them (see the functional pattern paper about an explanation why this
is necessary).

Best regards,

Michael

_______________________________________________
curry mailing list
curry_at_lists.RWTH-Aachen.DE
http://MailMan.RWTH-Aachen.DE/mailman/listinfo/curry

Received on Sa Mai 16 2015 - 17:40:45 CEST

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