packages feed

hsimport 0.7 → 0.7.1

raw patch · 4 files changed

+12/−7 lines, 4 filesdep +ilistdep +microlensdep −lensPVP ok

version bump matches the API change (PVP)

Dependencies added: ilist, microlens

Dependencies removed: lens

API changes (from Hackage documentation)

Files

CHANGELOG view
@@ -1,3 +1,7 @@+0.7.1+-----+* Switch from lens to microlens (for faster compiling)+ 0.7 --- * Changes for haskell-src-exts 1.17.0
hsimport.cabal view
@@ -1,5 +1,5 @@ name: hsimport-version: 0.7+version: 0.7.1 cabal-version: >=1.9.2 build-type: Simple license: BSD3@@ -34,7 +34,8 @@         base >=3 && <5,         cmdargs >=0.10.5 && <0.11,         haskell-src-exts >=1.17.0 && <1.18,-        lens >=3.9.2 && <4.14,+        ilist >=0.1 && <0.3,+        microlens ==0.4.*,         mtl >=2.1.2 && <2.3,         text >=0.11.3.1 && <1.3,         split >=0.2.2 && <0.3,@@ -61,7 +62,7 @@         hsimport -any     cpp-options: -DCABAL     hs-source-dirs: exe-    ghc-prof-options: -prof -fprof-auto -rtsopts+    ghc-prof-options: -fprof-auto -rtsopts     ghc-options: -W  test-suite hsimport-tests
lib/HsImport/ImportChange.hs view
@@ -7,7 +7,7 @@  import Data.Maybe import Data.List (find, (\\))-import Control.Lens+import Lens.Micro import qualified Language.Haskell.Exts as HS import qualified Data.Attoparsec.Text as A import HsImport.Symbol (Symbol(..))
lib/HsImport/ImportPos.hs view
@@ -8,8 +8,8 @@    ) where  import qualified Language.Haskell.Exts as HS+import Data.List.Index (ifoldl') import Data.List.Split (splitOn)-import Control.Lens  #if __GLASGOW_HASKELL__ < 710 import Control.Applicative ((<$>))@@ -50,8 +50,8 @@         Just (idx, _) -> Just $ imports !! idx         _             -> Nothing    where-      computeMatches :: Int -> Maybe (Int, Int) -> [String] -> Maybe (Int, Int)-      computeMatches idx matches mod =+      computeMatches :: Maybe (Int, Int) -> Int -> [String] -> Maybe (Int, Int)+      computeMatches matches idx mod =          let num' = numMatches splittedMod mod              in case matches of                      Just (_, num) | num' >= num -> Just (idx, num')