Adepted the modules to their new structure
[matthijs/master-project/cλash.git] / cλash / CLasH / Translator / TranslatorTypes.hs
1 --
2 -- Simple module providing some types used by Translator. These are in a
3 -- separate module to prevent circular dependencies in Pretty for example.
4 --
5 {-# LANGUAGE TemplateHaskell #-}
6 module CLasH.Translator.TranslatorTypes where
7
8 import qualified Control.Monad.Trans.State as State
9 import qualified Data.Map as Map
10 import qualified Data.Accessor.Template
11 import Data.Accessor
12
13 import qualified HscTypes
14
15 import qualified Language.VHDL.AST as AST
16
17 import CLasH.VHDL.VHDLTypes
18
19 data TranslatorSession = TranslatorSession {
20   tsCoreModule_ :: HscTypes.CoreModule, -- ^ The current module
21   tsNameCount_ :: Int -- ^ A counter that can be used to generate unique names
22 }
23
24 -- Derive accessors
25 $( Data.Accessor.Template.deriveAccessors ''TranslatorSession )
26
27 type TranslatorState = State.State TranslatorSession
28
29 -- vim: set ts=8 sw=2 sts=2 expandtab: