[Haskell-beginners] Is there a way to hide an existing data type so that I can use my own version?
Costello, Roger L.
costello at mitre.org
Tue Jul 31 13:26:29 CEST 2012
Ah, excellent. Thanks Henk-Jan.
This works perfectly:
--------------------------------------------------------
import Prelude hiding (Either, Left, Right)
data Either a b = Left a | Right b
deriving (Show)
--------------------------------------------------------
/Roger
-----Original Message-----
From: Henk-Jan van Tuyl [mailto:hjgtuyl at chello.nl]
Sent: Tuesday, July 31, 2012 7:19 AM
To: beginners at haskell.org; Costello, Roger L.
Subject: Re: [Haskell-beginners] Is there a way to hide an existing data type so that I can use my own version?
On Tue, 31 Jul 2012 13:08:38 +0200, Costello, Roger L.
<costello at mitre.org> wrote:
> import Prelude hiding Either
That should be:
import Prelude hiding (Either)
Regards,
Henk-Jan van Tuyl
--
http://Van.Tuyl.eu/
http://members.chello.nl/hjgtuyl/tourdemonad.html
Haskell programming
--
More information about the Beginners
mailing list