diff --git a/Data/FMList.hs b/Data/FMList.hs
--- a/Data/FMList.hs
+++ b/Data/FMList.hs
@@ -92,7 +92,6 @@
 import Control.Monad
 import Control.Applicative
 
-
 -- | 'FMList' is a 'foldMap' function wrapped up in a newtype.
 --
 newtype FMList a = FM { unFM :: forall m . Monoid m => (a -> m) -> m }
@@ -170,13 +169,13 @@
 
 
 head         :: FMList a -> a
-head l       = mhead l `fromJustOrError` "Data.FMList.head: empty list"
+head l       = mhead l `fromMaybeOrError` "Data.FMList.head: empty list"
 
 tail         :: FMList a -> FMList a
 tail l       = if null l then error "Data.FMList.tail: empty list" else drop (1::Int) l
 
 last         :: FMList a -> a
-last l       = getLast (unFM l (Last . Just)) `fromJustOrError` "Data.FMList.last: empty list"
+last l       = getLast (unFM l (Last . Just)) `fromMaybeOrError` "Data.FMList.last: empty list"
 
 init         :: FMList a -> FMList a
 init l       = if null l then error "Data.FMList.init: empty list" else reverse . drop (1::Int) . reverse $ l
@@ -184,12 +183,11 @@
 reverse      :: FMList a -> FMList a
 reverse l    = FM $ getDual . unFM l . (Dual .)
 
-
 flatten      :: Foldable t => FMList (t a) -> FMList a
 flatten      = transform foldMap
 
 filter       :: (a -> Bool) -> FMList a -> FMList a
-filter p     = transform (\f e -> if p e then f e else mempty)
+filter p     = transform (\f x -> if p x then f x else mempty)
 
 
 -- transform the foldMap to foldr with state.
@@ -219,8 +217,11 @@
 iterate f x  = x `cons` iterate f (f x)
 
 repeat       :: a -> FMList a
-repeat x     = xs where xs = x `cons` xs
+repeat       = cycle . one
 
+cycle        :: FMList a -> FMList a
+cycle l      = l >< cycle l >< l
+
 -- | 'unfoldr' builds an 'FMList' from a seed value from left to right.
 -- The function takes the element and returns 'Nothing'
 -- if it is done producing the list or returns 'Just' @(a,b)@, in which
@@ -273,6 +274,7 @@
 instance Monad FMList where
   return     = one
   m >>= g    = transform (\f -> foldMap f . g) m
+  fail _     = nil
 
 instance Applicative FMList where
   pure       = one
@@ -294,5 +296,5 @@
   show l     = "fromList " ++ (show $! toList l)
   
 
-fromJustOrError :: Maybe a -> String -> a
-fromJustOrError ma e = fromMaybe (error e) ma
+fromMaybeOrError :: Maybe a -> String -> a
+fromMaybeOrError ma e = fromMaybe (error e) ma
diff --git a/fmlist.cabal b/fmlist.cabal
--- a/fmlist.cabal
+++ b/fmlist.cabal
@@ -1,5 +1,5 @@
 name:                fmlist
-version:             0.7
+version:             0.8
 synopsis:            FoldMap lists
 description:         
   FoldMap lists are lists represented by their foldMap function.
