packages feed

hlint 1.8.15 → 1.8.16

raw patch · 4 files changed

+12/−11 lines, 4 filesdep ~cpphsPVP ok

version bump matches the API change (PVP)

Dependency ranges changed: cpphs

API changes (from Hackage documentation)

Files

data/Default.hs view
@@ -9,7 +9,6 @@ import Data.List as X import Data.Maybe import Data.Monoid-import Data.Ord import System.IO  import IO as System.IO@@ -41,10 +40,10 @@ error = compare x y == LT ==> x < y error = compare x y /= LT ==> x >= y error = compare x y == GT ==> x > y-error = compare (f x) (f y) ==> Data.Ord.comparing f x y-error = on compare f ==> Data.Ord.comparing f-error = x == y || x == z ==> x `elem` [y,z]-error = x /= y && x /= z ==> x `notElem` [y,z]+error = x == a || x == b || x == c ==> x `elem` [a,b,c]+error = x /= a && x /= b && x /= c ==> x `notElem` [a,b,c]+--error = compare (f x) (f y) ==> Data.Ord.comparing f x y -- not that great+--error = on compare f ==> Data.Ord.comparing f -- not that great  -- READ/SHOW 
hlint.cabal view
@@ -1,7 +1,7 @@ cabal-version:      >= 1.6 build-type:         Simple name:               hlint-version:            1.8.15+version:            1.8.16 -- license is GPL v2 only license:            GPL license-file:       LICENSE@@ -41,7 +41,7 @@         base == 4.*, process, filepath, directory, containers,         transformers >= 0.0 && < 0.3,         hscolour >= 1.17 && < 1.20,-        cpphs >= 1.11 && < 1.13,+        cpphs >= 1.11 && < 1.14,         haskell-src-exts >= 1.11 && < 1.12,         uniplate >= 1.5 && < 1.7 
src/CmdLine.hs view
@@ -84,7 +84,7 @@        ,Option ""  ["cpp-define"] (ReqArg Define "name[=value]") "CPP #define"        ,Option ""  ["cpp-include"] (ReqArg Include "dir") "CPP include path"        ,Option ""  ["cpp-simple"] (NoArg SimpleCpp) "Use a simple CPP (strip # lines)"-       ,Option ""  ["cpp-ansi"] (NoArg Ansi) "Use CPP in -ansi mode"+       ,Option ""  ["cpp-ansi"] (NoArg Ansi) "Use CPP in ANSI compatibility mode"        ]  
src/Hint/Structure.hs view
@@ -7,8 +7,8 @@ yes x y = if a then b else if c then d else e -- yes x y ; | a = b ; | c = d ; | otherwise = e x `yes` y = if a then b else if c then d else e -- yes x y ; | a = b ; | c = d ; | otherwise = e no x y = if a then b else c-foo b | c <- f b = c -- foo (f -> c) = c-foo x y b z | c:cs <- f g b = c -- foo x y (f g -> c:cs) z = c+-- foo b | c <- f b = c -- foo (f -> c) = c+-- foo x y b z | c:cs <- f g b = c -- foo x y (f g -> c:cs) z = c foo b | c <- f b = c + b foo b | c <- f b = c where f = here foo b | c <- f b = c where foo = b@@ -26,7 +26,6 @@  import Hint.Type import Util-import Data.List   structureHint :: DeclHint@@ -38,6 +37,8 @@     | length guards > 2 = [gen "Use guards" $ Pattern pat (GuardedRhss d guards) bind]     where guards = asGuards bod +{-+-- Do not suggest view patterns, they aren't something everyone likes sufficiently hints gen (Pattern pats (GuardedRhss _ [GuardedRhs _ [Generator _ pat (App _ op (view -> Var_ p))] bod]) bind)     | Just i <- findIndex (=~= (toNamed p :: Pat_)) pats     , p `notElem` (vars bod ++ vars bind)@@ -46,6 +47,7 @@        Pattern (take i pats ++ [PParen an $ PViewPat an op pat] ++ drop (i+1) pats) (UnGuardedRhs an bod) bind]     where         decsBind = nub $ concatMap declBind $ childrenBi bind+-}  hints gen (Pattern pats (GuardedRhss _ [GuardedRhs _ [test] bod]) bind)     | prettyPrint test `elem` ["otherwise","True"]