[don't treat promote or demote in tail call position as tail call safe
John Meacham <john@repetae.net>**20110131061557
 Ignore-this: d3f887d2f98df5c7e93bc2de335b5d36
] hunk ./src/Grin/Noodle.hs 66
---    f (Store v) = return Store `ap` g v
hunk ./src/Grin/Noodle.hs 163
-
-
+-- NOPs will not produce any code at run-time so we can tail-call through them.
+isNop (BaseOp Promote _) = True
+isNop (BaseOp Demote _) = True
+isNop _ = False
hunk ./src/Grin/Noodle.hs 195
+        cfunc (e :>>= v :-> op@(BaseOp _ v')) | isNop op && v == v' = do cfunc e