From 39fb1fd3cc248265dc3b12bf99b5f91e924517e4 Mon Sep 17 00:00:00 2001 From: Bryan O'Sullivan Date: Tue, 8 Feb 2011 13:44:01 -0800 Subject: [PATCH] Get working with newer mtl (and GHC 7) --- System/FilePath/Find.hs | 7 ++----- filemanip.cabal | 12 ++++++++++-- 2 files changed, 12 insertions(+), 7 deletions(-) diff --git a/System/FilePath/Find.hs b/System/FilePath/Find.hs index b66ff55..0f7244d 100644 --- a/System/FilePath/Find.hs +++ b/System/FilePath/Find.hs @@ -113,7 +113,7 @@ module System.FilePath.Find ( import Control.Exception import Control.Monad (foldM, forM, liftM, liftM2) -import Control.Monad.State (State(..), evalState) +import Control.Monad.State (State, evalState, get) import Data.Bits (Bits, (.&.)) import Data.List (sort) import System.Directory (getDirectoryContents) @@ -172,13 +172,10 @@ evalFI :: FindClause a -> a evalFI m p d s = evalClause m (mkFI p d s) -mkFindClause :: (FileInfo -> (a, FileInfo)) -> FindClause a -mkFindClause = FC . State - -- | Return the current 'FileInfo'. fileInfo :: FindClause FileInfo -fileInfo = mkFindClause $ \st -> (st, st) +fileInfo = FC $ get -- | Return the name of the file being visited. filePath :: FindClause FilePath diff --git a/filemanip.cabal b/filemanip.cabal index 7fb9bcb..0898903 100644 --- a/filemanip.cabal +++ b/filemanip.cabal @@ -1,5 +1,5 @@ Name: filemanip -Version: 0.3.5.1 +Version: 0.3.5.2 License: BSD3 License-File: LICENSE Author: Bryan O'Sullivan @@ -15,7 +15,7 @@ Build-type: Simple Extra-Source-Files: README.markdown Library - build-depends: base < 5, bytestring, directory, filepath, mtl == 1.1.*, unix-compat + build-depends: base < 5, bytestring, directory, filepath, mtl, unix-compat if !os(windows) build-depends: unix if impl(ghc >= 6.10) @@ -28,3 +28,11 @@ Library System.FilePath.Glob, System.FilePath.GlobPattern, System.FilePath.Manip + +source-repository head + type: mercurial + location: http://bitbucket.org/bos/filemanip + +source-repository head + type: git + location: http://github.com/bos/filemanip