10 Mar
2014
10 Mar
'14
6:35 p.m.
Ok, one reason is that the TypeRep won't be cached in the Dynamic value. Even in GHC 7.8 Typeable is defined as class Typeable a where typeRep# :: Proxy# a -> TypeRep instead of class Typeable a where typeRep :: Tagged a TypeRep Why? Is this an oversight? * Roman Cheplyaka <roma@ro-che.info> [2014-03-10 12:11:27+0200]
In Data.Dynamic, Dynamic is defined as
data Dynamic = Dynamic TypeRep Any
Does this have any advantage over a safer
data Dynamic = forall a. Typeable a => Dynamic a
?
Roman