projects
/
matthijs
/
master-project
/
cλash.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
570e26f
)
Add getGlobalBinders accessor.
author
Matthijs Kooijman
<m.kooijman@student.utwente.nl>
Sun, 21 Jun 2009 14:49:36 +0000
(16:49 +0200)
committer
Matthijs Kooijman
<m.kooijman@student.utwente.nl>
Sun, 21 Jun 2009 14:52:58 +0000
(16:52 +0200)
NormalizeTypes.hs
patch
|
blob
|
history
diff --git
a/NormalizeTypes.hs
b/NormalizeTypes.hs
index e959bbba42fe5e067278668cfca6ce1c048e3450..5c7c24a6e1623805f255c2f61e0122e83709e68d 100644
(file)
--- a/
NormalizeTypes.hs
+++ b/
NormalizeTypes.hs
@@
-47,3
+47,9
@@
getGlobalBind bndr = do
-- Adds a new global binding with the given value
addGlobalBind :: CoreBndr -> CoreExpr -> TransformSession ()
addGlobalBind bndr expr = modA tsBindings (Map.insert bndr expr)
+
+-- Returns a list of all global binders
+getGlobalBinders :: TransformSession [CoreBndr]
+getGlobalBinders = do
+ bindings <- getA tsBindings
+ return $ Map.keys bindings