[Haskell-cafe] can the default instances in GHC be recompiled
with overlap?
Jonathan Cast
jonathanccast at fastmail.fm
Mon Aug 25 18:46:18 EDT 2008
On Mon, 2008-08-25 at 15:44 -0700, Jason Dusek wrote:
> Brandon S. Allbery KF8NH <allbery at ece.cmu.edu> wrote:
> > Jason Dusek wrote:
> > >
> > > It is inconvenient for certain things. If I want to declare a
> > > special `instance Show [MyType] where...` I am out of luck.
> >
> > In this particular case, can't you just define showList?
>
> Will GHCi use that automatically? Probably not... Nor can I
> write nice codez with print, printf, &c. I have to use my
> silly function now. I want to be in the Show typeclass for
> clarity as well as convenience.
showList is a method of the Show type class...
http://haskell.org/ghc/docs/latest/html/libraries/base/Prelude.html#v%
3AshowList
jcc
More information about the Haskell-Cafe
mailing list