Skip to content

Commit 6335a25

Browse files
committed
Fix GHC < 8.6 build
It turns out we were relying on instances from a transitive dependency on base-orphans. Added that explicitly so that we don't regress on the instances provided with old GHCs.
1 parent 253fd3f commit 6335a25

File tree

2 files changed

+7
-0
lines changed

2 files changed

+7
-0
lines changed

patch.cabal

+3
Original file line numberDiff line numberDiff line change
@@ -39,6 +39,9 @@ library
3939
, transformers >= 0.5.6.0 && < 0.6
4040
, witherable >= 0.3 && < 0.4
4141

42+
if impl(ghc < 8.6) -- really, if base < 8.12
43+
build-depends: base-orphans >= 0.8 && < 0.9
44+
4245
exposed-modules: Data.Functor.Misc
4346
, Data.Monoid.DecidablyEmpty
4447
, Data.Patch

src/Data/Semigroup/Additive.hs

+4
Original file line numberDiff line numberDiff line change
@@ -14,6 +14,10 @@ module Data.Semigroup.Additive
1414
import Data.Functor.Const (Const (..))
1515
import Data.Functor.Identity
1616
import Data.Proxy
17+
#if !MIN_VERSION_base(4,12,0)
18+
-- for :*: and :.: semigroup instances
19+
import Data.Orphans ()
20+
#endif
1721
#if !MIN_VERSION_base(4,11,0)
1822
import Data.Semigroup (Semigroup (..))
1923
#endif

0 commit comments

Comments
 (0)