on master help sign in
moved data and typeable deriving of LAlt' to its definition
3f2e1afRui Barreiro
src/IRTS/JavaScript/LangTransforms.hs−2
@@ -29,8 +29,6 @@ import Data.Data
29import Data.Generics.Uniplate.Data
29import Data.Generics.Uniplate.Data
30import GHC.Generics (Generic)
30import GHC.Generics (Generic)
31
31
32−deriving instance Typeable a => Typeable (LAlt' a)
33−deriving instance Data a => Data (LAlt' a)
34deriving instance Typeable FDesc
32deriving instance Typeable FDesc
35deriving instance Data FDesc
33deriving instance Data FDesc
36deriving instance Typeable LVar
34deriving instance Typeable LVar
src/IRTS/Lang.hs+4−2
@@ -5,7 +5,7 @@ Copyright :
5License : BSD3
5License : BSD3
6Maintainer : The Idris Community.
6Maintainer : The Idris Community.
7-}
7-}
8−{-# LANGUAGE DeriveFunctor, DeriveGeneric, PatternGuards #-}
8+{-# LANGUAGE DeriveDataTypeable, DeriveFunctor, DeriveGeneric, PatternGuards #-}
9
9
10module IRTS.Lang where
10module IRTS.Lang where
11
11
@@ -14,7 +14,9 @@ import Idris.Core.TT
14
14
15import Control.Applicative hiding (Const)
15import Control.Applicative hiding (Const)
16import Control.Monad.State hiding (lift)
16import Control.Monad.State hiding (lift)
17+import Data.Data (Data)
17import Data.List
18import Data.List
19+import Data.Typeable (Typeable)
18import Debug.Trace
20import Debug.Trace
19import GHC.Generics (Generic)
21import GHC.Generics (Generic)
20
22
@@ -117,7 +119,7 @@ data FType = FArith ArithTy
117data LAlt' e = LConCase Int Name [Name] e
119data LAlt' e = LConCase Int Name [Name] e
118 | LConstCase Const e
120 | LConstCase Const e
119 | LDefaultCase e
121 | LDefaultCase e
120− deriving (Show, Eq, Functor)
122+ deriving (Show, Eq, Functor, Data, Typeable)
121
123
122type LAlt = LAlt' LExp
124type LAlt = LAlt' LExp
123
125