@@ -17,8 +17,6 @@ import Development.IDE.Functions.Compile (TcModuleResult,
1717import qualified Development.IDE.Functions.Compile as Compile
1818import Development.IDE.Functions.FindImports (Import(..))
1919import Development.IDE.Functions.DependencyInformation
20−import Data.Binary (Binary)
21−import qualified Data.Binary as Binary
2220import Data.Hashable
2321import Data.Typeable
2422import Development.Shake hiding (Env, newCache)
@@ -63,7 +61,7 @@ type instance RuleResult GenerateCore = GhcModule
6361
6462-- | We capture the subset of `DynFlags` that is computed by package initialization in a rule to
6563-- make session initialization cheaper by reusing it.
66−type instance RuleResult GeneratePackageState = Compile.PackageState
64+type instance RuleResult LoadPackageState = Compile.PackageState
6765
6866-- | Resolve the imports in a module to the list of either external packages or absolute file paths
6967-- for modules in the same package.
@@ -77,69 +75,58 @@ type instance RuleResult ReportImportCycles = ()
7775
7876data OfInterest = OfInterest
7977 deriving (Eq, Show, Typeable, Generic)
80−instance Binary OfInterest
8178instance Hashable OfInterest
8279instance NFData OfInterest
8380
8481data GetParsedModule = GetParsedModule
8582 deriving (Eq, Show, Typeable, Generic)
86−instance Binary GetParsedModule
8783instance Hashable GetParsedModule
8884instance NFData GetParsedModule
8985
9086data GetLocatedImports = GetLocatedImports
9187 deriving (Eq, Show, Typeable, Generic)
92−instance Binary GetLocatedImports
9388instance Hashable GetLocatedImports
9489instance NFData GetLocatedImports
9590
9691data GetDependencyInformation = GetDependencyInformation
9792 deriving (Eq, Show, Typeable, Generic)
98−instance Binary GetDependencyInformation
9993instance Hashable GetDependencyInformation
10094instance NFData GetDependencyInformation
10195
10296data ReportImportCycles = ReportImportCycles
10397 deriving (Eq, Show, Typeable, Generic)
104−instance Binary ReportImportCycles
10598instance Hashable ReportImportCycles
10699instance NFData ReportImportCycles
107100
108101data GetDependencies = GetDependencies
109102 deriving (Eq, Show, Typeable, Generic)
110−instance Binary GetDependencies
111103instance Hashable GetDependencies
112104instance NFData GetDependencies
113105
114106data TypeCheck = TypeCheck
115107 deriving (Eq, Show, Typeable, Generic)
116−instance Binary TypeCheck
117108instance Hashable TypeCheck
118109instance NFData TypeCheck
119110
120111data LoadPackage = LoadPackage InstalledUnitId
121112 deriving (Eq, Show, Typeable, Generic)
122−instance Binary LoadPackage
123113instance Hashable LoadPackage
124114instance NFData LoadPackage
125115
126116data GetSpanInfo = GetSpanInfo
127117 deriving (Eq, Show, Typeable, Generic)
128−instance Binary GetSpanInfo
129118instance Hashable GetSpanInfo
130119instance NFData GetSpanInfo
131120
132121data GenerateCore = GenerateCore
133122 deriving (Eq, Show, Typeable, Generic)
134−instance Binary GenerateCore
135123instance Hashable GenerateCore
136124instance NFData GenerateCore
137125
138−data GeneratePackageState = GeneratePackageState [FilePath] Bool [(String, [(String, String)])]
126+data LoadPackageState = LoadPackageState
139127 deriving (Eq, Show, Typeable, Generic)
140−instance Binary GeneratePackageState
141−instance Hashable GeneratePackageState
142−instance NFData GeneratePackageState
128+instance Hashable LoadPackageState
129+instance NFData LoadPackageState
143130
144131------------------------------------------------------------
145132-- Orphan Instances
@@ -171,10 +158,6 @@ instance NFData SpanInfo where
171158instance NFData Import where
172159 rnf = rwhnf
173160
174−instance Binary InstalledUnitId where
175− get = fmap stringToInstalledUnitId Binary.get
176− put = Binary.put . installedUnitIdString
177−
178161instance Hashable InstalledUnitId where
179162 hashWithSalt salt = hashWithSalt salt . installedUnitIdString
180163