X-Git-Url: http://git.megacz.com/?a=blobdiff_plain;f=Data%2FDynamic.hs;h=b83bbfa89c649ce0da0636776960eaccaf242b41;hb=6abdb1cebbb6f0f0b492ba98907056d11064bc83;hp=12bf1c493afe73d4f5db4b68940c1f45b9b50deb;hpb=8afc9fecd586d3c4f7ef9c69fb1686a79e5f441d;p=ghc-base.git diff --git a/Data/Dynamic.hs b/Data/Dynamic.hs index 12bf1c4..b83bbfa 100644 --- a/Data/Dynamic.hs +++ b/Data/Dynamic.hs @@ -1,4 +1,5 @@ -{-# OPTIONS_GHC -XNoImplicitPrelude #-} +{-# LANGUAGE CPP, NoImplicitPrelude #-} + ----------------------------------------------------------------------------- -- | -- Module : Data.Dynamic @@ -47,7 +48,7 @@ import Unsafe.Coerce #ifdef __GLASGOW_HASKELL__ import GHC.Base import GHC.Show -import GHC.Num +import GHC.Exception #endif #ifdef __HUGS__ @@ -93,6 +94,11 @@ instance Show Dynamic where showString ">>" #ifdef __GLASGOW_HASKELL__ +-- here so that it isn't an orphan: +instance Exception Dynamic +#endif + +#ifdef __GLASGOW_HASKELL__ type Obj = Any -- Use GHC's primitive 'Any' type to hold the dynamically typed value. --