Commit 0bc3cf2e authored by Francesco Gazzetta's avatar Francesco Gazzetta
Browse files

infix elem and isSuffixOf, increased readability

parent 82445dea
......@@ -335,7 +335,7 @@ filterAutogenModules pkg_descr0 = mapLib filterAutogenModuleLib $
pathsModule = autogenPathsModuleName pkg_descr0
filterFunction bi = \mn ->
mn /= pathsModule
&& not (elem mn (autogenModules bi))
&& not (mn `elem` autogenModules bi)
-- | Prepare a directory tree of source files for a snapshot version.
-- It is expected that the appropriate snapshot version has already been set
......
......@@ -92,7 +92,7 @@ extractMirrors hostname s0 = mapMaybe (parseURI . snd) . sort $ vals
isUrlBase :: String -> Maybe Int
isUrlBase s
| isSuffixOf ".urlbase" s, not (null ns), all isDigit ns = readMaybe ns
| ".urlbase" `isSuffixOf` s, not (null ns), all isDigit ns = readMaybe ns
| otherwise = Nothing
where
ns = take (length s - 8) s
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment