diff options
Diffstat (limited to 'compiler/utils/ListT.hs')
| -rw-r--r-- | compiler/utils/ListT.hs | 5 |
1 files changed, 4 insertions, 1 deletions
diff --git a/compiler/utils/ListT.hs b/compiler/utils/ListT.hs index c16701419d..105e27b3d4 100644 --- a/compiler/utils/ListT.hs +++ b/compiler/utils/ListT.hs @@ -1,3 +1,4 @@ +{-# LANGUAGE CPP #-} {-# LANGUAGE UndecidableInstances #-} {-# LANGUAGE Rank2Types #-} {-# LANGUAGE FlexibleInstances #-} @@ -67,9 +68,11 @@ instance Alternative (ListT f) where instance Monad (ListT m) where m >>= f = ListT $ \sk fk -> unListT m (\a fk' -> unListT (f a) sk fk') fk +#if !MIN_VERSION_base(4,13,0) fail = MonadFail.fail +#endif -instance MonadFail (ListT m) where +instance MonadFail.MonadFail (ListT m) where fail _ = ListT $ \_ fk -> fk instance MonadPlus (ListT m) where |
