Re: Negatively recursive data types

2001-07-04 Thread Koen Claessen
Keith Wansbrough wondered: | Does anyone have an example of a useful data type | involving negative recursion? Here is an example straight from practice. If we want to implement a datatype of predicate logic formulas, it is convenient to use higher-order syntax: type Name = String da

Re: Negatively recursive data types

2001-07-04 Thread Olaf Chitil
Lars Henrik Mathiesen wrote: > > > From: Keith Wansbrough <[EMAIL PROTECTED]> > > > > Hi... I'm currently looking at the semantics of recursive data types. > > One thing that Haskell allows, but the semantics for it is very hairy, > > is *negatively

Re: Negatively recursive data types

2001-07-04 Thread Lars Henrik Mathiesen
> From: Keith Wansbrough <[EMAIL PROTECTED]> > Date: Wed, 04 Jul 2001 18:27:05 +0100 > > Hi... I'm currently looking at the semantics of recursive data types. > One thing that Haskell allows, but the semantics for it is very hairy, > is *negatively* recursive dat

Negatively recursive data types

2001-07-04 Thread Keith Wansbrough
Hi... I'm currently looking at the semantics of recursive data types. One thing that Haskell allows, but the semantics for it is very hairy, is *negatively* recursive data types. That is, data types where the recursion occurs to the left of a function arrow. For example: data Ne