Re: Re[2]: ADT views Re: [Haskell] Views in Haskell

2007-01-31 Thread J. Garrett Morris
On 1/31/07, Bulat Ziganshin <[EMAIL PROTECTED]> wrote: i hope that now my idea is clear Yes - you've reiterated Wadler's original design, with an automatic creation of a type class. Erwig and Peyton-Jones, _Pattern Guards and Transformational Patterns_ (http://research.microsoft.com/~simonpj/

Re[2]: ADT views Re: [Haskell] Views in Haskell

2007-01-31 Thread Bulat Ziganshin
Hello David, Wednesday, January 31, 2007, 7:12:05 PM, you wrote: >> data Coord = Coord Float Float >> view of Coord = Polar Float Float where >> Polar r d= Coord (r*d) (r+d)-- construction >> Coord x y | x/=0 || y/=0 = Polar (x*y) (x+y)-- matching > This i