summaryrefslogtreecommitdiff
path: root/libraries/ghc-prim
diff options
context:
space:
mode:
authorBen Gamari <bgamari.foss@gmail.com>2016-01-13 14:53:02 +0100
committerBen Gamari <ben@smart-cactus.org>2016-01-13 14:53:03 +0100
commitac3cf68c378410724973e64be7198bb8720a6809 (patch)
tree7c7868b4411f7062391df13af0a8f1e47d13266b /libraries/ghc-prim
parentd44bc5c061e3f0ba459f835aba683c0366187b74 (diff)
downloadhaskell-ac3cf68c378410724973e64be7198bb8720a6809.tar.gz
Add missing type representations
Previously we were missing `Typeable` representations for several wired-in types (and their promoted constructors). These include, * `Nat` * `Symbol` * `':` * `'[]` Moreover, some constructors were incorrectly identified as being defined in `GHC.Types` whereas they were in fact defined in `GHC.Prim`. Ultimately this is just a temporary band-aid as there is general agreement that we should eliminate the manual definition of these representations entirely. Test Plan: Validate Reviewers: austin, hvr Subscribers: thomie Differential Revision: https://phabricator.haskell.org/D1769 GHC Trac Issues: #11120
Diffstat (limited to 'libraries/ghc-prim')
-rw-r--r--libraries/ghc-prim/GHC/Types.hs8
1 files changed, 8 insertions, 0 deletions
diff --git a/libraries/ghc-prim/GHC/Types.hs b/libraries/ghc-prim/GHC/Types.hs
index b30db97400..2ce4c7ee7e 100644
--- a/libraries/ghc-prim/GHC/Types.hs
+++ b/libraries/ghc-prim/GHC/Types.hs
@@ -43,6 +43,10 @@ import GHC.Prim
infixr 5 :
+-- Take note: All types defined here must have associated type representations
+-- defined in Data.Typeable.Internal.
+-- See Note [Representation of types defined in GHC.Types] below.
+
{- *********************************************************************
* *
Kinds
@@ -367,6 +371,10 @@ Note [Representations of types defined in GHC.Types]
The representations for the types defined in GHC.Types are
defined in GHC.Typeable.Internal.
+Any types defined here must also have a corresponding TyCon representation
+defined in Data.Typeable.Internal. Also, if the type is promotable it must also
+have a TyCon for each promoted data constructor.
+
-}
#include "MachDeps.h"