diff options
Diffstat (limited to 'compiler/GHC/Cmm')
-rw-r--r-- | compiler/GHC/Cmm/Dataflow.hs | 3 | ||||
-rw-r--r-- | compiler/GHC/Cmm/Dataflow/Graph.hs | 6 |
2 files changed, 6 insertions, 3 deletions
diff --git a/compiler/GHC/Cmm/Dataflow.hs b/compiler/GHC/Cmm/Dataflow.hs index fcabb1df0f..4f900c32ac 100644 --- a/compiler/GHC/Cmm/Dataflow.hs +++ b/compiler/GHC/Cmm/Dataflow.hs @@ -43,13 +43,14 @@ import Data.Array import Data.Maybe import Data.IntSet (IntSet) import qualified Data.IntSet as IntSet +import Data.Kind (Type) import GHC.Cmm.Dataflow.Block import GHC.Cmm.Dataflow.Graph import GHC.Cmm.Dataflow.Collections import GHC.Cmm.Dataflow.Label -type family Fact (x :: Extensibility) f :: * +type family Fact (x :: Extensibility) f :: Type type instance Fact C f = FactBase f type instance Fact O f = f diff --git a/compiler/GHC/Cmm/Dataflow/Graph.hs b/compiler/GHC/Cmm/Dataflow/Graph.hs index 3f361de0fb..de146c6a35 100644 --- a/compiler/GHC/Cmm/Dataflow/Graph.hs +++ b/compiler/GHC/Cmm/Dataflow/Graph.hs @@ -27,11 +27,13 @@ import GHC.Cmm.Dataflow.Label import GHC.Cmm.Dataflow.Block import GHC.Cmm.Dataflow.Collections +import Data.Kind + -- | A (possibly empty) collection of closed/closed blocks type Body n = LabelMap (Block n C C) -- | @Body@ abstracted over @block@ -type Body' block (n :: Extensibility -> Extensibility -> *) = LabelMap (block n C C) +type Body' block (n :: Extensibility -> Extensibility -> Type) = LabelMap (block n C C) ------------------------------- -- | Gives access to the anchor points for @@ -76,7 +78,7 @@ type Graph = Graph' Block -- | @Graph'@ is abstracted over the block type, so that we can build -- graphs of annotated blocks for example (Compiler.Hoopl.Dataflow -- needs this). -data Graph' block (n :: Extensibility -> Extensibility -> *) e x where +data Graph' block (n :: Extensibility -> Extensibility -> Type) e x where GNil :: Graph' block n O O GUnit :: block n O O -> Graph' block n O O GMany :: MaybeO e (block n O C) |