projects
/
matthijs
/
master-project
/
cλash.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
Add the new CoreTools module.
[matthijs/master-project/cλash.git]
/
Translator.hs
diff --git
a/Translator.hs
b/Translator.hs
index 92251eede3caf0dde2915ae9cf006f9078ce638f..396dfbc40e8e03769fea16d673281a0baeb01865 100644
(file)
--- a/
Translator.hs
+++ b/
Translator.hs
@@
-8,6
+8,9
@@
import qualified Var
import qualified Type
import qualified TyCon
import qualified DataCon
import qualified Type
import qualified TyCon
import qualified DataCon
+import qualified HscMain
+import qualified SrcLoc
+import qualified FastString
import qualified Maybe
import qualified Module
import qualified Data.Foldable as Foldable
import qualified Maybe
import qualified Module
import qualified Data.Foldable as Foldable
@@
-63,12
+66,17
@@
makeVHDL filename name stateful = do
listBind :: String -> String -> IO ()
listBind filename name = do
core <- loadModule filename
listBind :: String -> String -> IO ()
listBind filename name = do
core <- loadModule filename
- let
binds
= findBinds core [name]
+ let
[bind]
= findBinds core [name]
putStr "\n"
putStr "\n"
- putStr $ prettyShow bind
s
+ putStr $ prettyShow bind
putStr "\n\n"
putStr "\n\n"
- putStr $ showSDoc $ ppr bind
s
+ putStr $ showSDoc $ ppr bind
putStr "\n\n"
putStr "\n\n"
+ case bind of
+ NonRec b expr -> do
+ putStr $ showSDoc $ ppr $ CoreUtils.exprType expr
+ putStr "\n\n"
+ otherwise -> return ()
-- | Translate the binds with the given names from the given core module to
-- VHDL. The Bool in the tuple makes the function stateful (True) or
-- | Translate the binds with the given names from the given core module to
-- VHDL. The Bool in the tuple makes the function stateful (True) or