From 9cac249c847df63b9fc242bb539b9c841001200f Mon Sep 17 00:00:00 2001 From: Rob Rix Date: Thu, 21 Dec 2017 10:56:04 -0500 Subject: [PATCH] :memo: reset. --- src/Control/Monad/Effect/Fresh.hs | 2 ++ 1 file changed, 2 insertions(+) diff --git a/src/Control/Monad/Effect/Fresh.hs b/src/Control/Monad/Effect/Fresh.hs index 627f465e4..70733f3c0 100644 --- a/src/Control/Monad/Effect/Fresh.hs +++ b/src/Control/Monad/Effect/Fresh.hs @@ -15,6 +15,8 @@ data Fresh a where class Monad m => MonadFresh m where -- | Get a fresh variable name, guaranteed unused (since the last 'reset'). fresh :: m TName + + -- | Reset the sequence of variable names. Useful to avoid complicated alpha-equivalence comparisons when iteratively recomputing the results of an analysis til convergence. reset :: TName -> m () instance (Fresh :< fs) => MonadFresh (Eff fs) where