Use explicit language extensions & remove extension fields from base.cabal
[ghc-base.git] / Data / Dynamic.hs
index 7466897..b83bbfa 100644 (file)
@@ -1,4 +1,5 @@
-{-# OPTIONS_GHC -XNoImplicitPrelude #-}
+{-# LANGUAGE CPP, NoImplicitPrelude #-}
+
 -----------------------------------------------------------------------------
 -- |
 -- Module      :  Data.Dynamic
@@ -47,8 +48,7 @@ import Unsafe.Coerce
 #ifdef __GLASGOW_HASKELL__
 import GHC.Base
 import GHC.Show
-import GHC.Err
-import GHC.Num
+import GHC.Exception
 #endif
 
 #ifdef __HUGS__
@@ -94,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.
  --