diff options
author | Gregor Kleen <gkleen@yggdrasil.li> | 2016-05-27 23:41:44 +0200 |
---|---|---|
committer | Gregor Kleen <gkleen@yggdrasil.li> | 2016-05-27 23:41:44 +0200 |
commit | 97bde0359940a1f6fe2cdbc4bffb9bcaec2a0e54 (patch) | |
tree | 69765b244e33897557f249ef6edece8604033496 | |
parent | e04e707b1fb63b7857878e2d77c560abe3efd51b (diff) | |
download | events-97bde0359940a1f6fe2cdbc4bffb9bcaec2a0e54.tar events-97bde0359940a1f6fe2cdbc4bffb9bcaec2a0e54.tar.gz events-97bde0359940a1f6fe2cdbc4bffb9bcaec2a0e54.tar.bz2 events-97bde0359940a1f6fe2cdbc4bffb9bcaec2a0e54.tar.xz events-97bde0359940a1f6fe2cdbc4bffb9bcaec2a0e54.zip |
efficiency
-rw-r--r-- | events/src/Events/Types.hs | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/events/src/Events/Types.hs b/events/src/Events/Types.hs index 3414b68..22faf94 100644 --- a/events/src/Events/Types.hs +++ b/events/src/Events/Types.hs | |||
@@ -78,7 +78,7 @@ type Eval m a = StateT ObjCtx (ListT (StateT EvalCtx m)) a | |||
78 | evaluate :: MonadFix m => Eval m () -> m [Object] | 78 | evaluate :: MonadFix m => Eval m () -> m [Object] |
79 | evaluate x = catMaybes <$> mfix x' | 79 | evaluate x = catMaybes <$> mfix x' |
80 | where | 80 | where |
81 | x' = evalStateT (ListT.toList (objCtx <$> execStateT x def)) . flip (set ctxEvents) def . catMaybes | 81 | x' = evalStateT (ListT.toReverseList (objCtx <$> execStateT x def)) . flip (set ctxEvents) def . catMaybes |
82 | 82 | ||
83 | instance MonadState s m => MonadState s (ListT m) where | 83 | instance MonadState s m => MonadState s (ListT m) where |
84 | get = lift get | 84 | get = lift get |