hlint 1.8.16 → 1.8.17
raw patch · 3 files changed
+7/−5 lines, 3 filesPVP ok
version bump matches the API change (PVP)
API changes (from Hackage documentation)
Files
- hlint.cabal +1/−1
- src/CmdLine.hs +2/−0
- src/Util.hs +4/−4
hlint.cabal view
@@ -1,7 +1,7 @@ cabal-version: >= 1.6 build-type: Simple name: hlint-version: 1.8.16+version: 1.8.17 -- license is GPL v2 only license: GPL license-file: LICENSE
src/CmdLine.hs view
@@ -169,6 +169,7 @@ getFile :: [String] -> FilePath -> IO [FilePath]+getFile _ "-" = return ["-"] getFile exts file = do b <- doesDirectoryExist file if b then do@@ -181,6 +182,7 @@ getHintFile :: FilePath -> FilePath -> IO FilePath+getHintFile _ "-" = return "-" getHintFile dataDir x = do let poss = nub $ concat [x : [x <.> "hs" | takeExtension x /= ".hs"] | x <- [x,dataDir </> x]] f poss poss
src/Util.hs view
@@ -129,10 +129,10 @@ readFileEncoding :: Encoding -> FilePath -> IO String-readFileEncoding (Encoding_Internal x) = case x of- Nothing -> readFile- Just set -> \file -> do- h <- openFile file ReadMode+readFileEncoding (Encoding_Internal x) file = case x of+ Nothing -> if file == "-" then getContents else readFile file+ Just set -> do+ h <- if file == "-" then return stdin else openFile file ReadMode set h hGetContents h