Commit 673821b9 authored by Ryan Scott's avatar Ryan Scott

Migrate/remove old patches

* Migrate the patches for `doctest`, `free`, `persistent`, and `yesod-core`
  to the latest versions on Hackage.
* Remove the patches for `Cabal`, `bytes`, `cabal-doctest`, `ghc-paths`,
  `hsc2hs`, `polyparse`, `singleton-nats`, `tar`, `yaml`, and `zlib`, as
  more recent versions of these packages (that support GHC 8.8 and HEAD)
  are now available on Hackage.

I opted not to remove the `th-desugar-1.9`/`singletons-2.5.1` patches for
now, even though they are not the latest Hackage releases, since upgrading
them can be a nontrivial process (similar to the `primitive-0.6`/`-0.7`
situation).
parent 333f2347
Pipeline #9696 passed with stages
in 44 minutes and 39 seconds
diff --git a/Distribution/Simple/PreProcess.hs b/Distribution/Simple/PreProcess.hs
index 4933028..2af2316 100644
--- a/Distribution/Simple/PreProcess.hs
+++ b/Distribution/Simple/PreProcess.hs
@@ -122,6 +122,12 @@ data PreProcessor = PreProcessor {
-- preprocessor's output name format.
type PreProcessorExtras = FilePath -> IO [FilePath]
+-- | A newtype around 'PreProcessorExtras', useful for storing
+-- 'PreProcessorExtras' inside of another type constructor (e.g., a list)
+-- without impredicativity (recall that the 'IO' type, which is contained in
+-- 'PreProcessorExtras', is a synonym for @'HasCallStack' => Prelude.IO@, which
+-- is a polymorphic type).
+newtype WrappedPreProcessorExtras = WrapPPE { unWrapPPE :: PreProcessorExtras }
mkSimplePreProcessor :: (FilePath -> FilePath -> Verbosity -> IO ())
-> (FilePath, FilePath)
@@ -694,8 +700,8 @@ knownSuffixHandlers =
]
-- |Standard preprocessors with possible extra C sources: c2hs, hsc2hs.
-knownExtrasHandlers :: [ PreProcessorExtras ]
-knownExtrasHandlers = [ ppC2hsExtras, ppHsc2hsExtras ]
+knownExtrasHandlers :: [ WrappedPreProcessorExtras ]
+knownExtrasHandlers = [ WrapPPE ppC2hsExtras, WrapPPE ppHsc2hsExtras ]
-- | Find any extra C sources generated by preprocessing that need to
-- be added to the component (addresses issue #238).
@@ -732,7 +738,7 @@ preprocessExtras verbosity comp lbi = case comp of
pp :: FilePath -> IO [FilePath]
pp dir = (map (dir </>) . filter not_sub . concat)
<$> for knownExtrasHandlers
- (withLexicalCallStack (\f -> f dir))
+ (withLexicalCallStack (\f -> f dir) . unWrapPPE)
-- TODO: This is a terrible hack to work around #3545 while we don't
-- reorganize the directory layout. Basically, for the main
-- library, we might accidentally pick up autogenerated sources for
commit 3bbc80a8a708886f593c9591197d43191e7f31ba
Author: Ryan Scott <ryan.gl.scott@gmail.com>
Date: Fri Mar 15 14:09:31 2019 -0400
Adapt to base-4.13.0.0
diff --git a/src/Data/Bytes/Get.hs b/src/Data/Bytes/Get.hs
index 6ab1a04..fd5e26b 100644
--- a/src/Data/Bytes/Get.hs
+++ b/src/Data/Bytes/Get.hs
@@ -28,6 +28,7 @@ module Data.Bytes.Get
#if __GLASGOW_HASKELL__ < 710
import Control.Applicative
#endif
+import qualified Control.Monad.Fail as Fail
import Control.Monad.Reader
import Control.Monad.Trans.Except as Except
import Control.Monad.RWS.Lazy as Lazy
@@ -43,7 +44,7 @@ import Data.Int
import qualified Data.Serialize.Get as S
import Data.Word
-class (Integral (Remaining m), Monad m, Applicative m) => MonadGet m where
+class (Integral (Remaining m), Fail.MonadFail m, Applicative m) => MonadGet m where
-- | An 'Integral' number type used for unchecked skips and counting.
type Remaining m :: *
diff --git a/src/Data/Bytes/Serial.hs b/src/Data/Bytes/Serial.hs
index a669f15..b032665 100644
--- a/src/Data/Bytes/Serial.hs
+++ b/src/Data/Bytes/Serial.hs
@@ -594,7 +594,7 @@ instance GSerial U1 where
gdeserialize = return U1
instance GSerial V1 where
- gserialize _ = fail "I looked into the void."
+ gserialize _ = error "I looked into the void."
gdeserialize = fail "I looked into the void."
instance (GSerial f, GSerial g) => GSerial (f :*: g) where
@@ -772,7 +772,7 @@ instance GSerial1 U1 where
gdeserializeWith _ = return U1
instance GSerial1 V1 where
- gserializeWith _ = fail "I looked into the void."
+ gserializeWith _ = error "I looked into the void."
gdeserializeWith _ = fail "I looked into the void."
instance (GSerial1 f, GSerial1 g) => GSerial1 (f :*: g) where
commit 79490be79c4ad2e07fc8e43a9887fc21f1907f76
Author: Ryan Scott <ryan.gl.scott@gmail.com>
Date: Wed Jun 12 18:52:03 2019 -0400
Allow building with Cabal-3.0.*
diff --git a/src/Distribution/Extra/Doctest.hs b/src/Distribution/Extra/Doctest.hs
index 1beb9d2..94ca62b 100644
--- a/src/Distribution/Extra/Doctest.hs
+++ b/src/Distribution/Extra/Doctest.hs
@@ -69,8 +69,10 @@ import Distribution.PackageDescription
PackageDescription (), TestSuite (..))
import Distribution.Simple
(UserHooks (..), autoconfUserHooks, defaultMainWithHooks, simpleUserHooks)
+#if !(MIN_VERSION_Cabal(3,0,0))
import Distribution.Simple.BuildPaths
(autogenModulesDir)
+#endif
import Distribution.Simple.Compiler
(PackageDB (..), showCompilerId)
import Distribution.Simple.LocalBuildInfo
@@ -79,7 +81,11 @@ import Distribution.Simple.LocalBuildInfo
import Distribution.Simple.Setup
(BuildFlags (buildDistPref, buildVerbosity), HaddockFlags (haddockDistPref, haddockVerbosity), fromFlag, emptyBuildFlags)
import Distribution.Simple.Utils
- (createDirectoryIfMissingVerbose, findFile, rewriteFile)
+ (createDirectoryIfMissingVerbose, findFile)
+#if !(MIN_VERSION_Cabal(3,0,0))
+import Distribution.Simple.Utils
+ (rewriteFile)
+#endif
import Distribution.Text
(display, simpleParse)
import System.FilePath
@@ -103,6 +109,9 @@ import Distribution.Types.GenericPackageDescription
import Distribution.PackageDescription
(CondTree (..))
#endif
+#if MIN_VERSION_Cabal(2,5,0)
+import Distribution.Types.LibraryName (libraryNameString)
+#endif
#if MIN_VERSION_directory(1,2,2)
import System.Directory
@@ -432,7 +441,9 @@ generateBuildModule testSuiteName flags pkg lbi = do
isSpecific _ = False
mbLibraryName :: Library -> Name
-#if MIN_VERSION_Cabal(2,0,0)
+#if MIN_VERSION_Cabal(2,5,0)
+ mbLibraryName = NameLib . fmap unUnqualComponentName . libraryNameString . libName
+#elif MIN_VERSION_Cabal(2,0,0)
-- Cabal-2.0 introduced internal libraries, which are named.
mbLibraryName = NameLib . fmap unUnqualComponentName . libName
#else
commit 66e24478e71766222071e4af8096a5148302dd95
commit 8e6ff05a5463402f3c9451badc906e0c652eb19f
Author: Ryan Scott <ryan.gl.scott@gmail.com>
Date: Thu Aug 8 11:54:48 2019 -0400
Date: Tue Aug 27 18:50:25 2019 -0400
Allow building on GHC 8.9+
......
commit ef04b7e2b26461c3278a76dc2e1e093ce55d6d02
commit 4e5369ca48be46f46c8ae8270c8c7695feb59b70
Author: Ryan Scott <ryan.gl.scott@gmail.com>
Date: Wed Jul 3 13:20:47 2019 -0400
Date: Tue Aug 27 18:49:07 2019 -0400
Adapt to building with template-haskell-2.16.*
......
Only in ghc-paths-0.1.0.9/: ghc-paths.buildinfo
diff -ru ghc-paths-0.1.0.9.orig/Setup.hs ghc-paths-0.1.0.9/Setup.hs
--- ghc-paths-0.1.0.9.orig/Setup.hs 2012-12-03 07:00:02.000000000 -0500
+++ ghc-paths-0.1.0.9/Setup.hs 2019-06-26 10:55:50.814321566 -0400
@@ -26,7 +26,7 @@
where
defaultPostConf :: Args -> ConfigFlags -> PackageDescription -> LocalBuildInfo -> IO ()
defaultPostConf args flags pkgdescr lbi = do
- libdir_ <- rawSystemProgramStdoutConf (fromFlag (configVerbosity flags))
+ libdir_ <- getDbProgramOutput (fromFlag (configVerbosity flags))
ghcProgram (withPrograms lbi) ["--print-libdir"]
let libdir = reverse $ dropWhile isSpace $ reverse libdir_
cabal-version: >=1.10
Name: hsc2hs
Version: 0.68.4
x-revision: 1
Copyright: 2000, Marcin Kowalczyk
License: BSD3
License-File: LICENSE
Author: Marcin Kowalczyk <qrczak@knm.org.pl>
Maintainer: ghc-devs@haskell.org
Synopsis: A preprocessor that helps with writing Haskell bindings to C code
Bug-Reports: https://github.com/haskell/hsc2hs/issues
Description:
The hsc2hs program can be used to automate some parts of the
process of writing Haskell bindings to C code. It reads an
almost-Haskell source file with embedded special constructs, and
outputs a real Haskell file with these constructs processed, based
on information taken from some C headers. The extra constructs
provide Haskell counterparts of C types, values of C constants,
including sizes of C types, and access to fields of C structs.
.
For more details, see the
<http://downloads.haskell.org/~ghc/master/users-guide/utils.html#writing-haskell-interfaces-to-c-code-hsc2hs hsc2hs section>
in the GHC User's Guide.
Category: Development
Data-Files: template-hsc.h
build-type: Simple
tested-with: GHC==8.6.1, GHC==8.4.3, GHC==8.2.2, GHC==8.0.2, GHC==7.10.3, GHC==7.8.4, GHC==7.6.3, GHC==7.4.2, GHC==7.2.2, GHC==7.0.4
extra-source-files:
changelog.md
test/asm/*.s
flag in-ghc-tree
description: Are we in a GHC tree?
default: False
manual: True
source-repository head
Type: git
Location: https://github.com/haskell/hsc2hs.git
Executable hsc2hs
Default-Language: Haskell2010
Main-Is: Main.hs
Other-Modules:
C
Common
CrossCodegen
DirectCodegen
Flags
HSCParser
ATTParser
UtilsCodegen
Paths_hsc2hs
Other-Extensions: CPP, NoMonomorphismRestriction
Build-Depends: base >= 4.12 && < 5,
containers >= 0.4.0 && < 0.7,
directory >= 1.1.0 && < 1.4,
filepath >= 1.2.0 && < 1.5,
process >= 1.1.0 && < 1.7
if flag(in-ghc-tree)
cpp-options: -DIN_GHC_TREE
test-suite spec
main-is: Spec.hs
hs-source-dirs: .
other-modules: ATTParser
ghc-options: -Wall -threaded
type: exitcode-stdio-1.0
build-depends: base
, tasty
, tasty-hspec
default-language: Haskell2010
From 6324184483b20233a67cb9b26c59e751738c57c7 Mon Sep 17 00:00:00 2001
From: Herbert Valerio Riedel <hvr@gnu.org>
Date: Tue, 18 Dec 2018 23:03:58 +0100
Subject: [PATCH] MonadFail forward-compat
It turns out that the `fail` method was unused to begin with.
---
HSCParser.hs | 6 ++++--
1 file changed, 4 insertions(+), 2 deletions(-)
diff --git a/HSCParser.hs b/HSCParser.hs
index b2ef799..d855cf1 100644
--- a/HSCParser.hs
+++ b/HSCParser.hs
@@ -38,14 +38,16 @@ instance Monad Parser where
Success pos'' (out1++out2) imp'' b
Failure pos'' msg -> Failure pos'' msg
Failure pos' msg -> Failure pos' msg
- fail msg = Parser $ \pos _ -> Failure pos msg
+
+failp :: String -> Parser a
+failp msg = Parser $ \pos _ -> Failure pos msg
instance Alternative Parser where
empty = mzero
(<|>) = mplus
instance MonadPlus Parser where
- mzero = fail "mzero"
+ mzero = failp "mzero"
Parser m `mplus` Parser n =
Parser $ \pos s -> case m pos s of
success@(Success _ _ _ _) -> success
diff -ru persistent-2.10.0.orig/Database/Persist/Types/Base.hs persistent-2.10.0/Database/Persist/Types/Base.hs
--- persistent-2.10.0.orig/Database/Persist/Types/Base.hs 2019-04-14 22:27:15.000000000 -0400
+++ persistent-2.10.0/Database/Persist/Types/Base.hs 2019-04-19 16:55:07.211353215 -0400
diff -ru persistent-2.10.1.orig/Database/Persist/Types/Base.hs persistent-2.10.1/Database/Persist/Types/Base.hs
--- persistent-2.10.1.orig/Database/Persist/Types/Base.hs 2019-05-06 19:24:32.000000000 -0400
+++ persistent-2.10.1/Database/Persist/Types/Base.hs 2019-08-27 18:56:05.626530185 -0400
@@ -4,6 +4,7 @@
import Control.Arrow (second)
......
diff -ru polyparse-1.12.1.orig/src/Text/ParserCombinators/HuttonMeijer.hs polyparse-1.12.1/src/Text/ParserCombinators/HuttonMeijer.hs
--- polyparse-1.12.1.orig/src/Text/ParserCombinators/HuttonMeijer.hs 2001-09-08 21:46:40.000000000 -0400
+++ polyparse-1.12.1/src/Text/ParserCombinators/HuttonMeijer.hs 2019-03-15 09:39:11.347661735 -0400
@@ -63,7 +63,9 @@
-- >>= :: Parser a -> (a -> Parser b) -> Parser b
(P p) >>= f = P (\inp -> concat [papply (f v) out | (v,out) <- p inp])
+#if !(MIN_VERSION_base(4,13,0))
fail = Fail.fail
+#endif
instance Fail.MonadFail Parser where
-- fail :: String -> Parser a
diff -ru polyparse-1.12.1.orig/src/Text/ParserCombinators/HuttonMeijerWallace.hs polyparse-1.12.1/src/Text/ParserCombinators/HuttonMeijerWallace.hs
--- polyparse-1.12.1.orig/src/Text/ParserCombinators/HuttonMeijerWallace.hs 2001-09-08 21:46:40.000000000 -0400
+++ polyparse-1.12.1/src/Text/ParserCombinators/HuttonMeijerWallace.hs 2019-03-15 09:39:35.315799506 -0400
@@ -89,7 +89,9 @@
[ papply' (f v) s out | (v,s,out) <- res ]
Left err -> Left err
)
+#if !(MIN_VERSION_base(4,13,0))
fail = Fail.fail
+#endif
instance Fail.MonadFail (Parser s t e) where
-- fail :: String -> Parser s t e a
diff -ru polyparse-1.12.1.orig/src/Text/ParserCombinators/Poly/Base.hs polyparse-1.12.1/src/Text/ParserCombinators/Poly/Base.hs
--- polyparse-1.12.1.orig/src/Text/ParserCombinators/Poly/Base.hs 2001-09-08 21:46:40.000000000 -0400
+++ polyparse-1.12.1/src/Text/ParserCombinators/Poly/Base.hs 2019-03-15 09:40:29.772112703 -0400
@@ -26,6 +26,7 @@
) where
import Control.Applicative
+import qualified Control.Monad.Fail as Fail
#ifdef __NHC__
default (Integer,Double,[]) -- hack to avoid bizarre type defaulting error
@@ -62,7 +63,7 @@
-- There are two additional basic combinators that we expect to be implemented
-- afresh for every concrete type, but which (for technical reasons)
-- cannot be class methods. They are @next@ and @satisfy@.
-class (Functor p, Monad p, Applicative p, Alternative p, Commitment p) =>
+class (Functor p, Monad p, Fail.MonadFail p, Applicative p, Alternative p, Commitment p) =>
PolyParse p
infixl 3 `apply`
diff -ru polyparse-1.12.1.orig/src/Text/ParserCombinators/Poly/ByteStringChar.hs polyparse-1.12.1/src/Text/ParserCombinators/Poly/ByteStringChar.hs
--- polyparse-1.12.1.orig/src/Text/ParserCombinators/Poly/ByteStringChar.hs 2001-09-08 21:46:40.000000000 -0400
+++ polyparse-1.12.1/src/Text/ParserCombinators/Poly/ByteStringChar.hs 2019-03-15 09:41:30.340461321 -0400
@@ -39,7 +39,9 @@
instance Monad Parser where
return = pure
+#if !(MIN_VERSION_base(4,13,0))
fail = Fail.fail
+#endif
(P f) >>= g = P (continue . f)
where
continue (Success ts x) = let (P g') = g x in g' ts
diff -ru polyparse-1.12.1.orig/src/Text/ParserCombinators/Poly/ByteString.hs polyparse-1.12.1/src/Text/ParserCombinators/Poly/ByteString.hs
--- polyparse-1.12.1.orig/src/Text/ParserCombinators/Poly/ByteString.hs 2001-09-08 21:46:40.000000000 -0400
+++ polyparse-1.12.1/src/Text/ParserCombinators/Poly/ByteString.hs 2019-03-15 09:41:49.356570825 -0400
@@ -40,7 +40,9 @@
instance Monad Parser where
return = pure
+#if !(MIN_VERSION_base(4,13,0))
fail = Fail.fail
+#endif
(P f) >>= g = P (continue . f)
where
continue (Success ts x) = let (P g') = g x in g' ts
diff -ru polyparse-1.12.1.orig/src/Text/ParserCombinators/Poly/Lex.hs polyparse-1.12.1/src/Text/ParserCombinators/Poly/Lex.hs
--- polyparse-1.12.1.orig/src/Text/ParserCombinators/Poly/Lex.hs 2001-09-08 21:46:40.000000000 -0400
+++ polyparse-1.12.1/src/Text/ParserCombinators/Poly/Lex.hs 2019-03-15 09:41:14.892372380 -0400
@@ -56,7 +56,9 @@
instance Monad (Parser t) where
return = pure
+#if !(MIN_VERSION_base(4,13,0))
fail = Fail.fail
+#endif
(P f) >>= g = P (continue . f)
where
continue (Success ts x) = let (P g') = g x in g' ts
diff -ru polyparse-1.12.1.orig/src/Text/ParserCombinators/Poly/Parser.hs polyparse-1.12.1/src/Text/ParserCombinators/Poly/Parser.hs
--- polyparse-1.12.1.orig/src/Text/ParserCombinators/Poly/Parser.hs 2001-09-08 21:46:40.000000000 -0400
+++ polyparse-1.12.1/src/Text/ParserCombinators/Poly/Parser.hs 2019-03-15 09:40:51.276236444 -0400
@@ -40,7 +40,9 @@
instance Monad (Parser t) where
return = pure
+#if !(MIN_VERSION_base(4,13,0))
fail = Fail.fail
+#endif
(P f) >>= g = P (continue . f)
where
continue (Success ts x) = let (P g') = g x in g' ts
diff -ru polyparse-1.12.1.orig/src/Text/ParserCombinators/Poly/StateParser.hs polyparse-1.12.1/src/Text/ParserCombinators/Poly/StateParser.hs
--- polyparse-1.12.1.orig/src/Text/ParserCombinators/Poly/StateParser.hs 2001-09-08 21:46:40.000000000 -0400
+++ polyparse-1.12.1/src/Text/ParserCombinators/Poly/StateParser.hs 2019-03-15 09:42:06.188667777 -0400
@@ -43,7 +43,9 @@
instance Monad (Parser s t) where
return = pure
+#if !(MIN_VERSION_base(4,13,0))
fail = Fail.fail
+#endif
(P f) >>= g = P (\s-> continue . f s)
where
continue (Success (ts,s) x) = let (P g') = g x in g' s ts
diff -ru polyparse-1.12.1.orig/src/Text/ParserCombinators/Poly/StateText.hs polyparse-1.12.1/src/Text/ParserCombinators/Poly/StateText.hs
--- polyparse-1.12.1.orig/src/Text/ParserCombinators/Poly/StateText.hs 2001-09-08 21:46:40.000000000 -0400
+++ polyparse-1.12.1/src/Text/ParserCombinators/Poly/StateText.hs 2019-03-15 09:42:20.908752570 -0400
@@ -46,7 +46,9 @@
instance Monad (Parser s) where
return = pure
+#if !(MIN_VERSION_base(4,13,0))
fail = Fail.fail
+#endif
(P f) >>= g = P (\s-> continue . f s)
where
continue (Success (ts,s) x) = let (P g') = g x in g' s ts
diff -ru polyparse-1.12.1.orig/src/Text/ParserCombinators/Poly/Text.hs polyparse-1.12.1/src/Text/ParserCombinators/Poly/Text.hs
--- polyparse-1.12.1.orig/src/Text/ParserCombinators/Poly/Text.hs 2001-09-08 21:46:40.000000000 -0400
+++ polyparse-1.12.1/src/Text/ParserCombinators/Poly/Text.hs 2019-03-15 09:42:37.876850329 -0400
@@ -40,7 +40,9 @@
instance Monad Parser where
return = pure
+#if !(MIN_VERSION_base(4,13,0))
fail = Fail.fail
+#endif
(P f) >>= g = P (continue . f)
where
continue (Success ts x) = let (P g') = g x in g' ts
commit d47b43f4558086df438845fa203aba74968396f5
Author: Ryan Scott <ryan.gl.scott@gmail.com>
Date: Mon Jan 21 22:26:30 2019 -0500
Allow building with GHC 8.8
diff --git a/Data/Nat.hs b/Data/Nat.hs
index 1b64fe6..25dfa1c 100644
--- a/Data/Nat.hs
+++ b/Data/Nat.hs
@@ -3,7 +3,7 @@
FlexibleInstances, GADTs, TypeFamilies, TemplateHaskell,
InstanceSigs, TypeOperators, PolyKinds, StandaloneDeriving,
FlexibleContexts, AllowAmbiguousTypes, CPP, OverloadedStrings,
- EmptyCase #-}
+ EmptyCase, TypeApplications #-}
#if __GLASGOW_HASKELL__ >= 806
{-# LANGUAGE QuantifiedConstraints #-}
#endif
name: tar
version: 0.5.1.0
x-revision: 1
license: BSD3
license-file: LICENSE
author: Duncan Coutts <duncan@community.haskell.org>
Bjorn Bringert <bjorn@bringert.net>
maintainer: Duncan Coutts <duncan@community.haskell.org>
bug-reports: https://github.com/haskell/tar/issues
copyright: 2007 Bjorn Bringert <bjorn@bringert.net>
2008-2016 Duncan Coutts <duncan@community.haskell.org>
category: Codec
synopsis: Reading, writing and manipulating ".tar" archive files.
description: This library is for working with \"@.tar@\" archive files. It
can read and write a range of common variations of archive
format including V7, POSIX USTAR and GNU formats.
.
It provides support for packing and unpacking portable
archives. This makes it suitable for distribution but not
backup because details like file ownership and exact
permissions are not preserved.
.
It also provides features for random access to archive
content using an index.
build-type: Simple
cabal-version: >=1.8
extra-source-files: changelog.md
tested-with: GHC==7.0.4, GHC==7.2.2, GHC==7.4.2, GHC==7.6.3,
GHC==7.8.4, GHC==7.10.3, GHC==8.0.2, GHC==8.2.2, GHC==8.4.1
source-repository head
type: git
location: https://github.com/haskell/tar.git
flag old-time
default: False
flag old-bytestring
default: False
library
build-depends: base == 4.*,
filepath < 1.5,
array < 0.6,
containers >= 0.2 && < 0.7,
deepseq >= 1.1 && < 1.5
if flag(old-time)
build-depends: directory < 1.2, old-time < 1.2
else
build-depends: directory >= 1.2 && < 1.4, time < 1.9
if flag(old-bytestring)
build-depends: bytestring-builder >= 0.10.4.0.2 && < 0.11, bytestring == 0.9.*
else
build-depends: bytestring == 0.10.*
if !impl(ghc >= 8.0)
build-depends: semigroups == 0.18.*
exposed-modules:
Codec.Archive.Tar
Codec.Archive.Tar.Entry
Codec.Archive.Tar.Check
Codec.Archive.Tar.Index
other-modules:
Codec.Archive.Tar.Types
Codec.Archive.Tar.Read
Codec.Archive.Tar.Write
Codec.Archive.Tar.Pack
Codec.Archive.Tar.Unpack
Codec.Archive.Tar.Index.StringTable
Codec.Archive.Tar.Index.IntTrie
other-extensions:
BangPatterns
CPP
DeriveDataTypeable
GeneralizedNewtypeDeriving
PatternGuards
ScopedTypeVariables
ghc-options: -Wall -fno-warn-unused-imports
test-suite properties
type: exitcode-stdio-1.0
build-depends: base,
filepath,
array,
containers,
deepseq,
bytestring-handle,
QuickCheck == 2.*,
tasty >= 0.10 && <0.12,
tasty-quickcheck == 0.8.*
if flag(old-time)
build-depends: directory < 1.2, old-time
else
build-depends: directory >= 1.2, time
if flag(old-bytestring)
build-depends: bytestring-builder, bytestring >= 0.9 && <0.10
else
build-depends: bytestring >= 0.10
if !impl(ghc >= 8.0)
build-depends: semigroups == 0.18.*
hs-source-dirs: . test
main-is: test/Properties.hs
cpp-options: -DTESTS
other-modules:
Codec.Archive.Tar.Index
Codec.Archive.Tar.Index.StringTable
Codec.Archive.Tar.Index.IntTrie
-- shared w/ lib:tar component
other-modules:
Codec.Archive.Tar
Codec.Archive.Tar.Check
Codec.Archive.Tar.Pack
Codec.Archive.Tar.Read
Codec.Archive.Tar.Types
Codec.Archive.Tar.Unpack
Codec.Archive.Tar.Write
other-extensions:
CPP
BangPatterns,
DeriveDataTypeable
ScopedTypeVariables
ghc-options: -fno-ignore-asserts
benchmark bench
type: exitcode-stdio-1.0
hs-source-dirs: . bench
main-is: bench/Main.hs
build-depends: base,
bytestring >= 0.10,
filepath,
directory >= 1.2,
array,
containers,
deepseq,
time,
criterion >= 1.0
if !impl(ghc >= 8.0)
build-depends: semigroups == 0.18.*
-- shared w/ lib:tar component
other-modules:
Codec.Archive.Tar
Codec.Archive.Tar.Check
Codec.Archive.Tar.Index
Codec.Archive.Tar.Index.IntTrie
Codec.Archive.Tar.Index.StringTable
Codec.Archive.Tar.Pack
Codec.Archive.Tar.Read
Codec.Archive.Tar.Types
Codec.Archive.Tar.Unpack
Codec.Archive.Tar.Write
diff -ru tar-0.5.1.0.orig/Codec/Archive/Tar/Read.hs tar-0.5.1.0/Codec/Archive/Tar/Read.hs
--- tar-0.5.1.0.orig/Codec/Archive/Tar/Read.hs 2018-03-09 10:46:26.000000000 -0500
+++ tar-0.5.1.0/Codec/Archive/Tar/Read.hs 2019-03-15 18:06:31.923654193 -0400
@@ -23,6 +23,7 @@
import Data.Typeable (Typeable)
import Control.Applicative
import Control.Monad
+import qualified Control.Monad.Fail as Fail
import Control.DeepSeq
import qualified Data.ByteString as BS
@@ -252,6 +253,11 @@
return = pure
Error m >>= _ = Error m
Ok x >>= k = k x
+#if !(MIN_VERSION_base(4,13,0))
+ fail = Fail.fail
+#endif
+
+instance Fail.MonadFail (Partial e) where
fail = error "fail @(Partial e)"
{-# SPECIALISE readOct :: BS.ByteString -> Maybe Int #-}
diff -ru yaml-0.11.1.0.orig/src/Data/Yaml/Parser.hs yaml-0.11.1.0/src/Data/Yaml/Parser.hs
--- yaml-0.11.1.0.orig/src/Data/Yaml/Parser.hs 2018-10-12 02:00:28.000000000 -0400
+++ yaml-0.11.1.0/src/Data/Yaml/Parser.hs 2019-07-27 09:12:43.669748494 -0400
@@ -7,6 +7,7 @@
import Control.Applicative
import Control.Exception (Exception)
+import qualified Control.Monad.Fail as Fail
import Control.Monad (MonadPlus (..), liftM, ap)
import Control.Monad.Trans.Class (lift)
import Control.Monad.Trans.Resource (MonadThrow, throwM)
@@ -52,6 +53,10 @@
case f am of
Left t -> Left t
Right x -> unYamlParser (g x) am