Permalink
Browse files

removal of factored out modules

  • Loading branch information...
atzedijkstra committed Feb 6, 2013
1 parent fa2194f commit a555f9c59bc1c235555306f7f9ec5fb4b3393d11
Showing with 48 additions and 788 deletions.
  1. +1 −1 EHC/src/ehc/AbstractCore.chs
  2. +1 −1 EHC/src/ehc/AnaDomain.cag
  3. +0 −18 EHC/src/ehc/Base/AssocL.chs
  4. +1 −1 EHC/src/ehc/Base/BasicAnnot.chs
  5. +0 −195 EHC/src/ehc/Base/Binary.chs
  6. +2 −2 EHC/src/ehc/Base/Common.chs
  7. +1 −1 EHC/src/ehc/Base/HsName.chs
  8. +2 −2 EHC/src/ehc/Base/Optimize.chs
  9. +1 −1 EHC/src/ehc/Base/Pragma.chs
  10. +0 −460 EHC/src/ehc/Base/Serialize.chs
  11. +1 −1 EHC/src/ehc/Base/Strictness.chs
  12. +1 −1 EHC/src/ehc/Base/Target.chs
  13. +1 −1 EHC/src/ehc/Base/TreeTrie.chs
  14. +1 −1 EHC/src/ehc/Base/UID.chs
  15. +1 −1 EHC/src/ehc/CHR.chs
  16. +1 −1 EHC/src/ehc/CHR/Constraint.chs
  17. +1 −1 EHC/src/ehc/CHR/Key.chs
  18. +1 −1 EHC/src/ehc/CHR/Solve.chs
  19. +1 −1 EHC/src/ehc/Cmm.cag
  20. +1 −1 EHC/src/ehc/Core.cag
  21. +1 −1 EHC/src/ehc/EHC/CompilePhase/Output.chs
  22. +1 −1 EHC/src/ehc/EHC/CompilePhase/Parsers.chs
  23. +1 −1 EHC/src/ehc/Foreign.cag
  24. +1 −1 EHC/src/ehc/Gam.chs
  25. +1 −1 EHC/src/ehc/Gam/Base.chs
  26. +1 −1 EHC/src/ehc/Gam/ClGam.chs
  27. +1 −1 EHC/src/ehc/Gam/ClassDefaultGam.chs
  28. +1 −1 EHC/src/ehc/Gam/DataGam.chs
  29. +1 −1 EHC/src/ehc/Gam/FixityGam.chs
  30. +1 −1 EHC/src/ehc/Gam/PolGam.chs
  31. +0 −64 EHC/src/ehc/Gam/ScopeMapGam.chs
  32. +1 −1 EHC/src/ehc/Gam/TyGam.chs
  33. +1 −1 EHC/src/ehc/Gam/TyKiGam.chs
  34. +1 −1 EHC/src/ehc/Gam/ValGam.chs
  35. +1 −1 EHC/src/ehc/GrinByteCode.cag
  36. +1 −1 EHC/src/ehc/GrinCode.cag
  37. +2 −2 EHC/src/ehc/HI.chs
  38. +1 −1 EHC/src/ehc/LamInfo.chs
  39. +1 −1 EHC/src/ehc/Module.chs
  40. +1 −1 EHC/src/ehc/Opts/CommandLine.chs
  41. +1 −1 EHC/src/ehc/Pred.chs
  42. +1 −1 EHC/src/ehc/Pred/CHR.chs
  43. +1 −1 EHC/src/ehc/Pred/CommonCHR.chs
  44. +1 −1 EHC/src/ehc/Ty.cag
  45. +1 −1 EHC/src/ehc/TyCore.cag
  46. +1 −1 EHC/src/ehc/TyCore/Trf/Common.chs
  47. +1 −4 EHC/src/ehc/VarMp.chs
  48. +2 −2 EHC/src/ehc/files1.mk
@@ -14,7 +14,7 @@
%%[(8 codegen) import(Data.List, Data.Maybe, qualified Data.Map as Map, qualified Data.Set as Set, Control.Applicative((<|>),(<$>)))
%%]
-%%[(50 codegen grin) hs import(Control.Monad, {%{EH}Base.Binary}, {%{EH}Base.Serialize})
+%%[(50 codegen grin) hs import(Control.Monad, UHC.Util.Binary, UHC.Util.Serialize)
%%]
%%[(50 codegen grin) hs import(Data.Typeable(Typeable), Data.Generics(Data))
%%]
@@ -26,7 +26,7 @@ Analysis domains
%%[(8 codegen) hs export(AnaEval(..), AnaEvalL, RelevTy(..), RelevTyL, MbRelevTy, RelevQual(..), RelevQualL, RelevCoe(..), RelevCoeL)
%%]
-%%[(50 codegen grin) hs import(Control.Monad hiding(join), {%{EH}Base.Serialize}, {%{EH}Base.Binary}(liftM6))
+%%[(50 codegen grin) hs import(Control.Monad hiding(join), UHC.Util.Serialize, UHC.Util.Control.Monad(liftM6))
%%]
%%[(50 codegen grin) hs import(Data.Typeable(Typeable), Data.Generics(Data))
%%]
@@ -1,18 +0,0 @@
-%%[0
-%include lhs2TeX.fmt
-%include afp.fmt
-%%]
-
-%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
-%%% Association list
-%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
-
-%%[1 module {%{EH}Base.AssocL}
-%%]
-
-%%[1 import(UHC.Util.AssocL) export(module UHC.Util.AssocL)
-%%]
-
-%%[1
--- module is moved to uhc-util package
-%%]
@@ -14,7 +14,7 @@
%%[(8 codegen) hs import(qualified {%{EH}Config} as Cfg, {%{EH}Base.Bits})
%%]
-%%[(50 codegen) hs import(Control.Monad, {%{EH}Base.Binary}, {%{EH}Base.Serialize})
+%%[(50 codegen) hs import(Control.Monad, UHC.Util.Binary, UHC.Util.Serialize)
%%]
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
View
@@ -1,195 +0,0 @@
-%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
-%%% Additional stuff for use of Binary
-%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
-
-%%[50 hs module {%{EH}Base.Binary}
-%%]
-
-%%[50 import(UHC.Util.Binary) export (module UHC.Util.Binary)
-%%]
-%%[50 import(Data.Typeable(Typeable,Typeable1), Data.Generics.Aliases) export(module Data.Typeable)
-%%]
-%%[5020 import(Data.Generics(Data, constrIndex, toConstr, gmapQ, indexConstr, dataTypeOf, fromConstrM))
-%%]
-%%[50 import(Data.Generics(Data)) export(module Data.Generics)
-%%]
-%%[50 import(Data.Word, Data.Array, Control.Monad)
-%%]
-
-%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
-%%% Enum
-%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
-
-%%[50 export(putEnum, getEnum)
-putEnum :: Enum x => x -> Put
-putEnum x = put (fromEnum x)
-
-getEnum :: Enum x => Get x
-getEnum = do n <- get
- return (toEnum n)
-
-%%]
-
-%%[50 export(putEnum8, getEnum8)
-putEnum8 :: Enum x => x -> Put
-putEnum8 x = putWord8 (fromIntegral $ fromEnum x)
-
-getEnum8 :: Enum x => Get x
-getEnum8 = do n <- getWord8
- return (toEnum $ fromIntegral n)
-
-%%]
-
-%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
-%%% List abstraction
-%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
-
-%%[50 export(putList, getList)
-putList :: (Binary a, Binary b) => (x -> Bool) -> (x -> (a,b)) -> x -> Put
-putList isNil getCons x | isNil x = putWord8 0
- | otherwise = let (a,b) = getCons x in putWord8 1 >> put a >> put b
-
-getList :: (Binary a, Binary b) => x -> (a -> b -> x) -> Get x
-getList nil cons
- = do tag <- getWord8
- case tag of
- 0 -> return nil
- 1 -> liftM2 cons get get
-%%]
-
-%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
-%%% Utils
-%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
-
-%%[50 export(liftM6,liftM7,liftM8,liftM9)
-liftM6 :: (Monad m) => (a1 -> a2 -> a3 -> a4 -> a5 -> a6 -> r)
- -> m a1 -> m a2 -> m a3 -> m a4 -> m a5 -> m a6 -> m r
-liftM6 f m1 m2 m3 m4 m5 m6
- = do { x1 <- m1; x2 <- m2; x3 <- m3; x4 <- m4; x5 <- m5; x6 <- m6
- ; return (f x1 x2 x3 x4 x5 x6)
- }
-
-liftM7 :: (Monad m) => (a1 -> a2 -> a3 -> a4 -> a5 -> a6 -> a7 -> r)
- -> m a1 -> m a2 -> m a3 -> m a4 -> m a5 -> m a6 -> m a7 -> m r
-liftM7 f m1 m2 m3 m4 m5 m6 m7
- = do { x1 <- m1; x2 <- m2; x3 <- m3; x4 <- m4; x5 <- m5; x6 <- m6; x7 <- m7
- ; return (f x1 x2 x3 x4 x5 x6 x7)
- }
-
-liftM8 :: (Monad m) => (a1 -> a2 -> a3 -> a4 -> a5 -> a6 -> a7 -> a8 -> r)
- -> m a1 -> m a2 -> m a3 -> m a4 -> m a5 -> m a6 -> m a7 -> m a8 -> m r
-liftM8 f m1 m2 m3 m4 m5 m6 m7 m8
- = do { x1 <- m1; x2 <- m2; x3 <- m3; x4 <- m4; x5 <- m5; x6 <- m6; x7 <- m7; x8 <- m8
- ; return (f x1 x2 x3 x4 x5 x6 x7 x8)
- }
-
-liftM9 :: (Monad m) => (a1 -> a2 -> a3 -> a4 -> a5 -> a6 -> a7 -> a8 -> a9 -> r)
- -> m a1 -> m a2 -> m a3 -> m a4 -> m a5 -> m a6 -> m a7 -> m a8 -> m a9 -> m r
-liftM9 f m1 m2 m3 m4 m5 m6 m7 m8 m9
- = do { x1 <- m1; x2 <- m2; x3 <- m3; x4 <- m4; x5 <- m5; x6 <- m6; x7 <- m7; x8 <- m8; x9 <- m9
- ; return (f x1 x2 x3 x4 x5 x6 x7 x8 x9)
- }
-%%]
-
-%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
-%%% Generic put & get
-%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
-
-%%[50
-%%]
-instance (Data a, Typeable a) => Binary a where
- put = gput
- get = gget
-
-%%[50
-%%]
--- | Generic put.
-gput :: Data a => a -> Put
-gput = general
- `extQ` char
- `extQ` int
- `extQ` integer
- `extQ` float
- `extQ` double
- `extQ` string
- -- `extQ` arr
- -- `extQ` array
- where
- -- Generic case
- general :: Data a => a -> Put
- general x = let n :: Word8
- n = fromIntegral (constrIndex (toConstr x))
- in foldr1 (>>) (putWord8 n : gmapQ gput x)
-
- -- Base cases
- char :: Char -> Put
- char = put
-
- int :: Int -> Put
- int = put
-
- integer :: Integer -> Put
- integer = put
-
- float :: Float -> Put
- float = put
-
- double :: Double -> Put
- double = put
-
- string :: String -> Put
- string = put
-
- -- array :: (Ix a, Data a, Data b) => Array a b -> Put
- -- array a = foldr1 (>>) (gmapQ gput (bounds a)) >> foldr1 (>>) (gmapQ gput (elems a))
-
- -- arr :: (Data e) => Array Int e -> Put
- -- arr a = gput (bounds a) >> gput (elems a)
-
--- | Generic get.
-gget :: forall a. Data a => Get a
-gget = general
- `extR` char
- `extR` int
- `extR` integer
- `extR` float
- `extR` double
- `extR` string where
- -- Generic case
- general :: forall a. Data a => Get a
- general = do n <- getWord8
- let f :: Get a -> a -- just to get the type
- f = error "impossible"
- i = indexConstr (dataTypeOf (f general)) (fromIntegral n)
- fromConstrM gget i
-
- -- Base cases
- char :: Get Char
- char = get
-
- int :: Get Int
- int = get
-
- integer :: Get Integer
- integer = get
-
- float :: Get Float
- float = get
-
- double :: Get Double
- double = get
-
- string :: Get String
- string = get
-
-%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
-%%% Instances: Binary
-%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
-
-%%[50
-%%]
-instance Enum a => Binary a where
- put e = put (fromEnum e)
- get = do n <- get
- return (toEnum n)
-
@@ -13,7 +13,7 @@
%%[1 import({%{EH}Base.UID}) export(module {%{EH}Base.UID})
%%]
-%%[1 import({%{EH}Base.AssocL}) export(module {%{EH}Base.AssocL})
+%%[1 import(UHC.Util.AssocL) export(module UHC.Util.AssocL)
%%]
%%[1 import(UHC.Util.Pretty, Data.List) export(ppSpaced, ppCon, ppCmt)
@@ -85,7 +85,7 @@
%%[(8 codegen) import({%{EH}Base.Strictness}) export(module {%{EH}Base.Strictness})
%%]
-%%[50 import(Control.Monad, {%{EH}Base.Binary}, {%{EH}Base.Serialize})
+%%[50 import(Control.Monad, UHC.Util.Binary, UHC.Util.Serialize)
%%]
%%[9999 import({%{EH}Base.Hashable})
@@ -43,7 +43,7 @@ HsNameUniqifier to guarantee such an invariant.
%%[10 export(hsnConcat)
%%]
-%%[50 import(Control.Monad, {%{EH}Base.Binary}, {%{EH}Base.Serialize})
+%%[50 import(Control.Monad, UHC.Util.Binary, UHC.Util.Serialize)
%%]
%%[99 import(Data.Hashable)
@@ -7,11 +7,11 @@
%%[(8 codegen) import(qualified Data.Set as Set,qualified Data.Map as Map,Data.List)
%%]
-%%[(8 codegen) import({%{EH}Base.AssocL})
+%%[(8 codegen) import(UHC.Util.AssocL)
%%]
%%[(8 codegen) import(UHC.Util.Pretty,UHC.Util.Utils)
%%]
-%%[(50 codegen) import({%{EH}Base.Binary}, {%{EH}Base.Serialize} )
+%%[(50 codegen) import(UHC.Util.Binary, UHC.Util.Serialize )
%%]
%%[doesWhat doclatex
@@ -11,7 +11,7 @@
%%]
%%[99 import({%{EH}Base.HsName},{%{EH}Base.Target})
%%]
-%%[99 import({%{EH}Base.Binary}, {%{EH}Base.Serialize})
+%%[99 import(UHC.Util.Binary, UHC.Util.Serialize)
%%]
%%[99 import(Control.Monad)
%%]
Oops, something went wrong.

0 comments on commit a555f9c

Please sign in to comment.