Genericshow
  Home FAQ Contact Sign in
 
Advanced search
MATCHING GROUPS



more...
POPULAR GROUPS

more...

found 3 articles for 0.303 sec
Jonathan Cast wrote: > Type case is easy: > > genericShow :: Typeable a => a -> String > genericShow x = fromJust $ do > s <- cast x :: Maybe String > return s > `mplus` do > n <- cast x :: Maybe Int > return (show n) >     

Group: fa.haskell · Group Profile · Search for Genericshow in fa.haskell
Author: Ben Franksen
Date: Apr 25, 2008 14:09

On 18 Apr 2008, at 9:29 PM, Ryan Ingram wrote: WARNING: RANT AHEAD. WARNING: RESPONSE IN THE SPIRIT OF THE ORIGINAL AHEAD. Hopefully this fires off some productive discussion on how to fix these problems! {-# GHC_OPTIONS -foverlapping-instances -fundecidable-instances #-} :) What you want to work is precisely what this allows. Don't get me wrong: I think the idea of typeclasses
Show full article (0.72Kb) · Show article thread
WARNING: RANT AHEAD. Hopefully this fires off some productive discussion on how to fix these problems! Don't get me wrong: I think the idea of typeclasses is great. Their implementation in Haskell comes so close to being awesome and then falls short, and that's almost worse than not being awesome in the first place! Some examples of things I think you should be able to do, that just Do     

Group: fa.haskell · Group Profile · Search for Genericshow in fa.haskell
Author: Jonathan Cast
Date: Apr 18, 2008 22:01

Show full article (7.40Kb) · Show article thread
    

Group: fa.haskell · Group Profile · Search for Genericshow in fa.haskell
Author: Ryan Ingram
Date: Apr 18, 2008 21:29

Show full article (3.77Kb)