@@ -238,7 +238,7 @@ data Package = Package
238238 --
239239 -- @since 0.1.0.0
240240 }
241- deriving (Show , Eq , Ord )
241+ deriving (Eq , Ord , Show )
242242
243243data PHpack = PHpack
244244 { phOriginal :: ! TreeEntry
@@ -248,12 +248,12 @@ data PHpack = PHpack
248248 , phVersion :: ! Version
249249 -- ^ Version of Hpack used
250250 }
251- deriving (Show , Eq , Ord )
251+ deriving (Eq , Ord , Show )
252252
253253data PackageCabal
254254 = PCCabalFile ! TreeEntry -- ^ TreeEntry of Cabal file
255255 | PCHpack ! PHpack
256- deriving (Show , Eq , Ord )
256+ deriving (Eq , Ord , Show )
257257
258258cabalFileName :: PackageName -> SafeFilePath
259259cabalFileName name =
@@ -268,7 +268,9 @@ cabalFileName name =
268268--
269269-- @since 0.1.0.0
270270newtype Revision = Revision Word
271- deriving (Generic , Show , Eq , NFData , Data , Typeable , Ord , Hashable , Display , PersistField , PersistFieldSql )
271+ deriving ( Data , Display , Eq , Generic , Hashable , NFData , Ord , PersistField
272+ , PersistFieldSql , Show
273+ )
272274
273275-- | Represents a SQL database connection.
274276
@@ -391,7 +393,7 @@ data ResolvedPath t = ResolvedPath
391393 , resolvedAbsolute :: ! (Path Abs t )
392394 -- ^ Absolute path resolved against base directory loaded from.
393395 }
394- deriving (Show , Eq , Generic , Ord )
396+ deriving (Eq , Generic , Ord , Show )
395397
396398instance NFData (ResolvedPath t )
397399
@@ -404,7 +406,7 @@ instance NFData (ResolvedPath t)
404406data RawPackageLocation
405407 = RPLImmutable ! RawPackageLocationImmutable
406408 | RPLMutable ! (ResolvedPath Dir )
407- deriving (Show , Eq , Generic )
409+ deriving (Eq , Generic , Show )
408410
409411instance NFData RawPackageLocation
410412
@@ -416,7 +418,7 @@ instance NFData RawPackageLocation
416418data PackageLocation
417419 = PLImmutable ! PackageLocationImmutable
418420 | PLMutable ! (ResolvedPath Dir )
419- deriving (Show , Eq , Generic )
421+ deriving (Eq , Generic , Show )
420422
421423instance NFData PackageLocation
422424
@@ -439,7 +441,7 @@ data RawPackageLocationImmutable
439441 = RPLIHackage ! PackageIdentifierRevision ! (Maybe TreeKey )
440442 | RPLIArchive ! RawArchive ! RawPackageMetadata
441443 | RPLIRepo ! Repo ! RawPackageMetadata
442- deriving (Show , Eq , Ord , Generic )
444+ deriving (Eq , Generic , Ord , Show )
443445
444446instance NFData RawPackageLocationImmutable
445447
@@ -507,7 +509,7 @@ data PackageLocationImmutable
507509 = PLIHackage ! PackageIdentifier ! BlobKey ! TreeKey
508510 | PLIArchive ! Archive ! PackageMetadata
509511 | PLIRepo ! Repo ! PackageMetadata
510- deriving (Generic , Show , Eq , Ord , Typeable )
512+ deriving (Eq , Generic , Ord , Show )
511513
512514instance NFData PackageLocationImmutable
513515
@@ -569,7 +571,7 @@ data RawArchive = RawArchive
569571 --
570572 -- @since 0.1.0.0
571573 }
572- deriving (Generic , Show , Eq , Ord , Typeable )
574+ deriving (Eq , Generic , Ord , Show )
573575
574576instance NFData RawArchive
575577
@@ -596,7 +598,7 @@ data Archive = Archive
596598 --
597599 -- @since 0.1.0.0
598600 }
599- deriving (Generic , Show , Eq , Ord , Typeable )
601+ deriving (Eq , Generic , Ord , Show )
600602
601603instance NFData Archive
602604
@@ -612,7 +614,7 @@ toRawArchive archive =
612614--
613615-- @since 0.1.0.0
614616data RepoType = RepoGit | RepoHg
615- deriving (Generic , Show , Eq , Ord , Typeable )
617+ deriving (Eq , Generic , Ord , Show )
616618
617619instance NFData RepoType
618620
@@ -651,7 +653,7 @@ data Repo = Repo
651653 --
652654 -- @since 0.1.0.0
653655 }
654- deriving (Generic , Eq , Ord , Typeable )
656+ deriving (Eq , Generic , Ord )
655657
656658instance NFData Repo
657659
@@ -682,7 +684,7 @@ data AggregateRepo = AggregateRepo
682684 { aRepo :: ! SimpleRepo
683685 , aRepoSubdirs :: [(Text , RawPackageMetadata )]
684686 }
685- deriving (Show , Generic , Eq , Ord , Typeable )
687+ deriving (Eq , Generic , Ord , Show )
686688
687689-- | Group input repositories by non-subdir values.
688690toAggregateRepos :: [(Repo , RawPackageMetadata )] -> [AggregateRepo ]
@@ -709,7 +711,7 @@ data SimpleRepo = SimpleRepo
709711 , sRepoCommit :: ! Text
710712 , sRepoType :: ! RepoType
711713 }
712- deriving (Show , Generic , Eq , Ord , Typeable )
714+ deriving (Eq , Generic , Ord , Show )
713715
714716instance Display SimpleRepo where
715717 display (SimpleRepo url commit typ) =
@@ -832,8 +834,8 @@ class HasPantryConfig env where
832834--
833835-- @since 0.1.0.0
834836newtype FileSize = FileSize Word
835- deriving ( Show , Eq , Ord , Typeable , Generic , Display , Hashable , NFData
836- , PersistField , PersistFieldSql , ToJSON , FromJSON
837+ deriving ( Display , Eq , FromJSON , Generic , Hashable , NFData , Ord , PersistField
838+ , PersistFieldSql , Show , ToJSON
837839 )
838840
839841-- | A key for looking up a blob, which combines the SHA256 hash of the contents
@@ -845,7 +847,7 @@ newtype FileSize = FileSize Word
845847--
846848-- @since 0.1.0.0
847849data BlobKey = BlobKey ! SHA256 ! FileSize
848- deriving (Eq , Ord , Typeable , Generic )
850+ deriving (Eq , Generic , Ord )
849851
850852instance NFData BlobKey
851853
@@ -972,7 +974,7 @@ data CabalFileInfo
972974 -- reproducibility.
973975 --
974976 -- @since 0.1.0.0
975- deriving (Generic , Show , Eq , Ord , Typeable )
977+ deriving (Eq , Generic , Ord , Show )
976978
977979instance NFData CabalFileInfo
978980
@@ -990,7 +992,7 @@ instance Display CabalFileInfo where
990992-- @since 0.1.0.0
991993data PackageIdentifierRevision
992994 = PackageIdentifierRevision ! PackageName ! Version ! CabalFileInfo
993- deriving (Generic , Eq , Ord , Typeable )
995+ deriving (Eq , Generic , Ord )
994996
995997instance NFData PackageIdentifierRevision
996998
@@ -1146,7 +1148,6 @@ data PantryException
11461148 | ParseSnapNameException ! Text
11471149 | HpackLibraryException ! (Path Abs File ) ! String
11481150 | HpackExeException ! FilePath ! (Path Abs Dir ) ! SomeException
1149- deriving Typeable
11501151
11511152instance Exception PantryException where
11521153
@@ -2178,10 +2179,10 @@ data BuildFile
21782179 = BFCabal ! SafeFilePath ! TreeEntry
21792180 | BFHpack ! TreeEntry
21802181 -- We don't need SafeFilePath for Hpack since it has to be package.yaml file
2181- deriving (Show , Eq )
2182+ deriving (Eq , Show )
21822183
21832184data FileType = FTNormal | FTExecutable
2184- deriving (Show , Eq , Enum , Bounded , Ord )
2185+ deriving (Bounded , Enum , Eq , Ord , Show )
21852186
21862187instance PersistField FileType where
21872188 toPersistValue FTNormal = PersistInt64 1
@@ -2201,10 +2202,10 @@ data TreeEntry = TreeEntry
22012202 { teBlob :: ! BlobKey
22022203 , teType :: ! FileType
22032204 }
2204- deriving (Show , Eq , Ord )
2205+ deriving (Eq , Ord , Show )
22052206
22062207newtype SafeFilePath = SafeFilePath Text
2207- deriving (Show , Eq , Ord , Display )
2208+ deriving (Display , Eq , Ord , Show )
22082209
22092210instance PersistField SafeFilePath where
22102211 toPersistValue = toPersistValue . unSafeFilePath
@@ -2250,7 +2251,7 @@ hpackSafeFilePath =
22502251--
22512252-- @since 0.1.0.0
22522253newtype TreeKey = TreeKey BlobKey
2253- deriving (Show , Eq , Ord , Generic , Typeable , ToJSON , FromJSON , NFData , Display )
2254+ deriving (Display , Eq , FromJSON , Generic , NFData , Ord , Show , ToJSON )
22542255
22552256-- | Represents the contents of a tree, which is a mapping from
22562257-- relative file paths to 'TreeEntry's.
@@ -2261,7 +2262,7 @@ newtype Tree
22612262 -- In the future, consider allowing more lax parsing
22622263 -- See: https://www.fpcomplete.com/blog/2018/07/pantry-part-2-trees-keys
22632264 -- TreeTarball !PackageTarball
2264- deriving (Show , Eq , Ord )
2265+ deriving (Eq , Ord , Show )
22652266
22662267renderTree :: Tree -> ByteString
22672268renderTree = BL. toStrict . toLazyByteString . go
@@ -2460,7 +2461,7 @@ data OptionalSubdirs
24602461 = OSSubdirs ! (NonEmpty Text )
24612462 | OSPackageMetadata ! Text ! RawPackageMetadata
24622463 -- ^ subdirectory and package metadata
2463- deriving (Show , Eq , Generic )
2464+ deriving (Eq , Generic , Show )
24642465
24652466instance NFData OptionalSubdirs
24662467
@@ -2483,7 +2484,7 @@ data RawPackageMetadata = RawPackageMetadata
24832484 --
24842485 -- @since 0.1.0.0
24852486 }
2486- deriving (Show , Eq , Ord , Generic , Typeable )
2487+ deriving (Eq , Generic , Ord , Show )
24872488
24882489instance NFData RawPackageMetadata
24892490
@@ -2507,7 +2508,7 @@ data PackageMetadata = PackageMetadata
25072508 --
25082509 -- @since 0.1.0.0
25092510 }
2510- deriving (Show , Eq , Ord , Generic , Typeable )
2511+ deriving (Eq , Generic , Ord , Show )
25112512
25122513-- i PackageMetadata
25132514instance NFData PackageMetadata
@@ -2541,7 +2542,7 @@ toRawPM pm = RawPackageMetadata (Just name) (Just version) (Just $ pmTreeKey pm)
25412542--
25422543-- @since 0.1.0.0
25432544newtype RelFilePath = RelFilePath Text
2544- deriving (Show , ToJSON , FromJSON , Eq , Ord , Generic , Typeable , NFData , Display )
2545+ deriving (Display , Eq , FromJSON , Generic , NFData , Ord , Show , ToJSON )
25452546
25462547-- | Location that an archive is stored at
25472548--
@@ -2555,7 +2556,7 @@ data ArchiveLocation
25552556 -- ^ Archive stored at a local file path
25562557 --
25572558 -- @since 0.1.0.0
2558- deriving (Show , Eq , Ord , Generic , Typeable )
2559+ deriving (Eq , Generic , Ord , Show )
25592560
25602561instance NFData ArchiveLocation
25612562
@@ -2817,7 +2818,7 @@ rpmEmpty = RawPackageMetadata Nothing Nothing Nothing
28172818--
28182819-- @since 0.1.0.0
28192820newtype CabalString a = CabalString { unCabalString :: a }
2820- deriving (Show , Eq , Ord , Typeable )
2821+ deriving (Eq , Ord , Show )
28212822
28222823-- I'd like to use coerce here, but can't due to roles. unsafeCoerce
28232824-- could work, but let's avoid unsafe code.
@@ -2891,7 +2892,7 @@ data HpackExecutable
28912892 -- ^ Compiled in library
28922893 | HpackCommand ! FilePath
28932894 -- ^ Executable at the provided path
2894- deriving (Show , Read , Eq , Ord )
2895+ deriving (Eq , Ord , Read , Show )
28952896
28962897
28972898-- | Which compiler a snapshot wants to use. The build tool may elect to do some
@@ -2905,7 +2906,7 @@ data WantedCompiler
29052906 ! Version
29062907 ! Version
29072908 -- ^ GHCJS version followed by GHC version
2908- deriving (Show , Eq , Ord , Generic )
2909+ deriving (Eq , Generic , Ord , Show )
29092910
29102911instance NFData WantedCompiler
29112912
@@ -3178,7 +3179,7 @@ data RawSnapshotLocation
31783179 -- ^ Snapshot synonym (LTS/Nightly).
31793180 --
31803181 -- @since 0.5.0.0
3181- deriving (Show , Eq , Ord , Generic )
3182+ deriving (Eq , Generic , Ord , Show )
31823183
31833184instance NFData RawSnapshotLocation
31843185
@@ -3228,7 +3229,7 @@ data SnapshotLocation
32283229 -- ^ Snapshot at a local file path.
32293230 --
32303231 -- @since 0.1.0.0
3231- deriving (Show , Eq , Ord , Generic )
3232+ deriving (Eq , Generic , Ord , Show )
32323233
32333234instance NFData SnapshotLocation
32343235
@@ -3360,7 +3361,7 @@ data RawSnapshotLayer = RawSnapshotLayer
33603361 --
33613362 -- @since 0.1.0.0
33623363 }
3363- deriving (Show , Eq , Generic )
3364+ deriving (Eq , Generic , Show )
33643365
33653366instance NFData RawSnapshotLayer
33663367
@@ -3452,7 +3453,7 @@ data SnapshotLayer = SnapshotLayer
34523453 --
34533454 -- @since 0.1.0.0
34543455 }
3455- deriving (Show , Eq , Generic )
3456+ deriving (Eq , Generic , Show )
34563457
34573458instance ToJSON SnapshotLayer where
34583459 toJSON snap = object $ concat
@@ -3494,7 +3495,7 @@ toRawSnapshotLayer sl = RawSnapshotLayer
34943495--
34953496-- @since 0.1.0.0
34963497newtype SnapshotCacheHash = SnapshotCacheHash { unSnapshotCacheHash :: SHA256 }
3497- deriving ( Show )
3498+ deriving Show
34983499
34993500-- | Get the path to the global hints cache file
35003501getGlobalHintsFile :: HasPantryConfig env => RIO env (Path Abs File )
@@ -3532,7 +3533,7 @@ data GlobalHintsLocation
35323533 -- ^ Download the global hints from the given URL.
35333534 | GHLFilePath ! (ResolvedPath File )
35343535 -- ^ Global hints at a local file path.
3535- deriving (Show , Eq , Ord , Generic )
3536+ deriving (Eq , Generic , Ord , Show )
35363537
35373538instance NFData GlobalHintsLocation
35383539
0 commit comments