diff options
author | Jose Pedro Magalhaes <jpm@cs.ox.ac.uk> | 2013-02-07 13:59:51 +0000 |
---|---|---|
committer | Jose Pedro Magalhaes <jpm@cs.ox.ac.uk> | 2013-02-12 08:44:07 +0000 |
commit | 94d8b995aeca1b2fcee9467a0f2bdf0d9dc64069 (patch) | |
tree | 38d7b675254bbb238d0d7478b5b7b2cfb610b898 /testsuite/tests/safeHaskell/safeLanguage | |
parent | dc30d9834829a5e68abef5ee9b8b628f68f0b871 (diff) | |
download | haskell-94d8b995aeca1b2fcee9467a0f2bdf0d9dc64069.tar.gz |
Implement poly-kinded Typeable
This patch makes the Data.Typeable.Typeable class work with arguments of any
kind. In particular, this removes the Typeable1..7 class hierarchy, greatly
simplyfing the whole Typeable story. Also added is the AutoDeriveTypeable
language extension, which will automatically derive Typeable for all types and
classes declared in that module. Since there is now no good reason to give
handwritten instances of the Typeable class, those are ignored (for backwards
compatibility), and a warning is emitted.
The old, kind-* Typeable class is now called OldTypeable, and lives in the
Data.OldTypeable module. It is deprecated, and should be removed in some future
version of GHC.
Diffstat (limited to 'testsuite/tests/safeHaskell/safeLanguage')
-rw-r--r-- | testsuite/tests/safeHaskell/safeLanguage/SafeLang13.hs | 2 | ||||
-rw-r--r-- | testsuite/tests/safeHaskell/safeLanguage/SafeLang14.hs | 2 |
2 files changed, 2 insertions, 2 deletions
diff --git a/testsuite/tests/safeHaskell/safeLanguage/SafeLang13.hs b/testsuite/tests/safeHaskell/safeLanguage/SafeLang13.hs index 9be68a3abb..e11b61658a 100644 --- a/testsuite/tests/safeHaskell/safeLanguage/SafeLang13.hs +++ b/testsuite/tests/safeHaskell/safeLanguage/SafeLang13.hs @@ -5,7 +5,7 @@ module Main where import SafeLang13_A -import Data.Typeable +import Data.OldTypeable data H = H String deriving (Typeable, Show) diff --git a/testsuite/tests/safeHaskell/safeLanguage/SafeLang14.hs b/testsuite/tests/safeHaskell/safeLanguage/SafeLang14.hs index 59e8386ac1..98e29fbceb 100644 --- a/testsuite/tests/safeHaskell/safeLanguage/SafeLang14.hs +++ b/testsuite/tests/safeHaskell/safeLanguage/SafeLang14.hs @@ -5,7 +5,7 @@ module Main where import SafeLang14_A -import Data.Typeable +import Data.OldTypeable data H = H String deriving (Typeable, Show) |