packages feed

hls-graph 1.3.0.0 → 1.4.0.0

raw patch · 8 files changed

+58/−40 lines, 8 filesPVP ok

version bump matches the API change (PVP)

API changes (from Hackage documentation)

- Development.IDE.Graph.Database: shakeRunDatabase :: ShakeDatabase -> [Action a] -> IO ([a], [IO ()])
+ Development.IDE.Graph.Database: SomeShakeValue :: k -> SomeShakeValue
+ Development.IDE.Graph.Database: data SomeShakeValue
+ Development.IDE.Graph.Database: instance Data.Hashable.Class.Hashable Development.IDE.Graph.Database.SomeShakeValue
+ Development.IDE.Graph.Database: instance GHC.Classes.Eq Development.IDE.Graph.Database.SomeShakeValue
+ Development.IDE.Graph.Database: instance GHC.Show.Show Development.IDE.Graph.Database.SomeShakeValue
+ Development.IDE.Graph.Database: shakeRunDatabaseForKeys :: Maybe [SomeShakeValue] -> ShakeDatabase -> [Action a] -> IO ([a], [IO ()])

Files

hls-graph.cabal view
@@ -1,6 +1,6 @@ cabal-version: 2.4 name:          hls-graph-version:       1.3.0.0+version:       1.4.0.0 synopsis:      Haskell Language Server internal graph API description:   Please see the README on GitHub at <https://github.com/haskell/haskell-language-server#readme>
src/Development/IDE/Graph.hs view
@@ -19,7 +19,7 @@     reschedule,     ) where -import qualified Development.Shake as Shake-import Development.IDE.Graph.Internal.Action-import Development.IDE.Graph.Internal.Options-import Development.IDE.Graph.Internal.Rules+import           Development.IDE.Graph.Internal.Action+import           Development.IDE.Graph.Internal.Options+import           Development.IDE.Graph.Internal.Rules+import qualified Development.Shake                      as Shake
src/Development/IDE/Graph/Classes.hs view
@@ -3,4 +3,4 @@     Show(..), Typeable, Eq(..), Hashable(..), Binary(..), NFData(..)     ) where -import Development.Shake.Classes+import           Development.Shake.Classes
src/Development/IDE/Graph/Database.hs view
@@ -1,18 +1,36 @@ +{-# LANGUAGE ExistentialQuantification #-} module Development.IDE.Graph.Database(     Shake.ShakeDatabase,+    SomeShakeValue(..),     shakeOpenDatabase,-    shakeRunDatabase,+    shakeRunDatabaseForKeys,     Shake.shakeProfileDatabase,     ) where -import qualified Development.Shake.Database as Shake-import Development.IDE.Graph.Internal.Action-import Development.IDE.Graph.Internal.Options-import Development.IDE.Graph.Internal.Rules+import           Data.Typeable+import           Development.IDE.Graph.Internal.Action+import           Development.IDE.Graph.Internal.Options+import           Development.IDE.Graph.Internal.Rules+import           Development.Shake                      (ShakeValue)+import           Development.Shake.Classes+import qualified Development.Shake.Database             as Shake  shakeOpenDatabase :: ShakeOptions -> Rules () -> IO (IO Shake.ShakeDatabase, IO ()) shakeOpenDatabase a b = Shake.shakeOpenDatabase (fromShakeOptions a) (fromRules b) -shakeRunDatabase :: Shake.ShakeDatabase -> [Action a] -> IO ([a], [IO ()])-shakeRunDatabase a b = Shake.shakeRunDatabase a (map fromAction b)+data SomeShakeValue = forall k . ShakeValue k => SomeShakeValue k+instance Eq SomeShakeValue where SomeShakeValue a == SomeShakeValue b = cast a == Just b+instance Hashable SomeShakeValue where hashWithSalt s (SomeShakeValue x) = hashWithSalt s x+instance Show SomeShakeValue where show (SomeShakeValue x) = show x++shakeRunDatabaseForKeys+    :: Maybe [SomeShakeValue]+      -- ^ Set of keys changed since last run. 'Nothing' means everything has changed+    -> Shake.ShakeDatabase+    -> [Action a]+    -> IO ([a], [IO ()])+shakeRunDatabaseForKeys _keys a b =+    -- Shake upstream does not accept the set of keys changed yet+    -- https://github.com/ndmitchell/shake/pull/802+    Shake.shakeRunDatabase a (map fromAction b)
src/Development/IDE/Graph/Internal/Action.hs view
@@ -1,14 +1,14 @@ {-# LANGUAGE GeneralizedNewtypeDeriving #-}-{-# LANGUAGE TypeFamilies #-}+{-# LANGUAGE TypeFamilies               #-}  module Development.IDE.Graph.Internal.Action where -import qualified Development.Shake as Shake-import qualified Development.Shake.Rule as Shake-import Development.Shake.Classes-import Control.Exception-import Control.Monad.IO.Class-import Control.Monad.Fail+import           Control.Exception+import           Control.Monad.Fail+import           Control.Monad.IO.Class+import qualified Development.Shake         as Shake+import           Development.Shake.Classes+import qualified Development.Shake.Rule    as Shake  newtype Action a = Action {fromAction :: Shake.Action a}     deriving (Monad, Applicative, Functor, MonadIO, MonadFail)
src/Development/IDE/Graph/Internal/Options.hs view
@@ -2,18 +2,18 @@  module Development.IDE.Graph.Internal.Options where -import qualified Development.Shake as Shake-import qualified Data.HashMap.Strict as Map-import Development.IDE.Graph.Internal.Action-import Development.IDE.Graph.Internal.Rules-import Data.Dynamic+import           Data.Dynamic+import qualified Data.HashMap.Strict                   as Map+import           Development.IDE.Graph.Internal.Action+import           Development.IDE.Graph.Internal.Rules+import qualified Development.Shake                     as Shake  data ShakeOptions = ShakeOptions {-    shakeThreads :: Int,-    shakeFiles :: FilePath,-    shakeExtra :: Maybe Dynamic,+    shakeThreads            :: Int,+    shakeFiles              :: FilePath,+    shakeExtra              :: Maybe Dynamic,     shakeAllowRedefineRules :: Bool,-    shakeTimings :: Bool+    shakeTimings            :: Bool     }  shakeOptions :: ShakeOptions
src/Development/IDE/Graph/Internal/Rules.hs view
@@ -1,15 +1,15 @@ {-# LANGUAGE GeneralizedNewtypeDeriving #-}-{-# LANGUAGE TypeFamilies #-}+{-# LANGUAGE TypeFamilies               #-}  module Development.IDE.Graph.Internal.Rules where -import qualified Development.Shake as Shake-import qualified Development.Shake.Rule as Shake-import Development.Shake.Classes-import Development.IDE.Graph.Internal.Action-import Control.Monad.IO.Class-import Control.Monad.Fail-import qualified Data.ByteString as BS+import           Control.Monad.Fail+import           Control.Monad.IO.Class+import qualified Data.ByteString                       as BS+import           Development.IDE.Graph.Internal.Action+import qualified Development.Shake                     as Shake+import           Development.Shake.Classes+import qualified Development.Shake.Rule                as Shake  newtype Rules a = Rules {fromRules :: Shake.Rules a}     deriving (Monoid, Semigroup, Monad, Applicative, Functor, MonadIO, MonadFail)
src/Development/IDE/Graph/Rule.hs view
@@ -10,6 +10,6 @@     apply, apply1,     ) where -import qualified Development.Shake.Rule as Shake-import Development.IDE.Graph.Internal.Action-import Development.IDE.Graph.Internal.Rules+import           Development.IDE.Graph.Internal.Action+import           Development.IDE.Graph.Internal.Rules+import qualified Development.Shake.Rule                as Shake