HaRe 0.7.2.2 → 0.7.2.3
raw patch · 3 files changed
+16/−18 lines, 3 filesdep ~ghc-mod
Dependency ranges changed: ghc-mod
Files
- ChangeLog +2/−0
- HaRe.cabal +4/−9
- src/Language/Haskell/Refact/Utils/Monad.hs +10/−9
ChangeLog view
@@ -1,3 +1,5 @@+2014-05-02 v0.7.2.3+ * Update for ghc-mod 4.1.0 2014-04-03 v0.7.2.2 * Fix renaming so that it also renames types in the export list of a module
HaRe.cabal view
@@ -1,5 +1,5 @@ Name: HaRe-Version: 0.7.2.2+Version: 0.7.2.3 Author: Chris Brown, Huiqing Li, Simon Thompson, Alan Zimmerman Maintainer: Alan Zimmerman Stability: Alpha@@ -54,9 +54,7 @@ , ghc-paths , ghc-prim , ghc-syb-utils- , ghc-mod >= 4.0- -- , ghc-mod >= 3.1.6 && <= 3.1.7- -- , lens+ , ghc-mod >= 4.1.0 , mtl , old-time , pretty@@ -121,9 +119,7 @@ , ghc-paths , ghc-prim , ghc-syb-utils- , ghc-mod >= 4.0- -- , ghc-mod >= 3.1.6 && <= 3.1.7- -- , lens+ , ghc-mod >= 4.1.0 , mtl , old-time , parsec@@ -173,8 +169,7 @@ , ghc-paths == 0.1.* , ghc-prim , ghc-syb-utils- , ghc-mod >= 4.0- -- , ghc-mod >= 3.1.6 && <= 3.1.7+ , ghc-mod >= 4.1.0 , hspec , mtl , old-time
src/Language/Haskell/Refact/Utils/Monad.hs view
@@ -179,16 +179,16 @@ , operators = False , detailed = False , qualified = False- , expandSplice = False , lineSeparator = rsetLineSeparator settings- , packageId = Nothing -- TODO: work this through if needed }- (_readLog,mcabal) <- initializeFlagsWithCradle opt cradle (options settings) True - case mcabal of- Just cabal -> do+ -- (_readLog,mcabal) <- initializeFlagsWithCradle opt cradle (options settings) True+ initializeFlagsWithCradle opt cradle+ -- initializeFlagsWithCradle :: GhcMonad m => Options -> Cradle -> m ()+ case cradleCabalFile cradle of+ Just cabalFile -> do -- targets <- liftIO $ cabalAllTargets cabal- targets <- liftIO $ getCabalAllTargets cradle cabal+ targets <- liftIO $ getCabalAllTargets cradle cabalFile -- liftIO $ warningM "HaRe" $ "initGhcSession:targets=" ++ show targets logm $ "initGhcSession:targets=" ++ show targets @@ -232,15 +232,16 @@ -- --------------------------------------------------------------------- --- getCabalAllTargets :: Cradle -> PackageDescription -> IO ([FilePath],[FilePath],[FilePath],[FilePath])-getCabalAllTargets cradle cabal = do+getCabalAllTargets :: Cradle -> FilePath -> IO ([FilePath],[FilePath],[FilePath],[FilePath])+getCabalAllTargets cradle cabalFile = do currentDir <- getCurrentDirectory -- let cabalDir = gfromJust "getCabalAllTargets" (cradleCabalDir cradle) let cabalDir = cradleRootDir cradle setCurrentDirectory cabalDir - (libs,exes,tests,benches) <- liftIO $ cabalAllTargets cabal+ pkgDesc <- liftIO $ parseCabalFile cabalFile+ (libs,exes,tests,benches) <- liftIO $ cabalAllTargets pkgDesc setCurrentDirectory currentDir let -- libs' = addCurrentDir libs