haskell-checkers / checkers

Check properties on standard classes and data structures
Other
79 stars 13 forks source link

v0.5.5 fails to build with GHC 8.10.1 #44

Closed sjakobi closed 4 years ago

sjakobi commented 4 years ago
src/Test/QuickCheck/Checkers.hs:256:30: error:
    Ambiguous occurrence ‘First’
    It could refer to
       either ‘Data.Monoid.First’,
              imported from ‘Data.Monoid’ at src/Test/QuickCheck/Checkers.hs:(53,1)-(57,27)
           or ‘Data.Semigroup.First’,
              imported from ‘Data.Semigroup’ at src/Test/QuickCheck/Checkers.hs:69:1-21
    |
256 | instance EqProp a => EqProp (First a)
    |                              ^^^^^

src/Test/QuickCheck/Checkers.hs:257:30: error:
    Ambiguous occurrence ‘Last’
    It could refer to
       either ‘Data.Monoid.Last’,
              imported from ‘Data.Monoid’ at src/Test/QuickCheck/Checkers.hs:(53,1)-(57,27)
           or ‘Data.Semigroup.Last’,
              imported from ‘Data.Semigroup’ at src/Test/QuickCheck/Checkers.hs:69:1-21
    |
257 | instance EqProp a => EqProp (Last a)
    |                              ^^^^

I think the issue was introduced in https://github.com/conal/checkers/commit/e7bb6fcbe4c1440131b7306a8a45ab8a1210e7ce.

@isovector Could you possibly take a look?

sjakobi commented 4 years ago

Note that Data.Monoid.{First,Last} were not removed in 8.10, despite the haddocks saying so: http://downloads.haskell.org/~ghc/8.10.1/docs/html/libraries/base-4.14.0.0/Data-Monoid.html#t:First

sjakobi commented 4 years ago

Some discussion on the deprecation of these types can be found here: https://gitlab.haskell.org/ghc/ghc/issues/15028

isovector commented 4 years ago

That's what I get for trusting Haskell documentation :(

sjakobi commented 4 years ago

That's what I get for trusting Haskell documentation :(

Yeah, it's kinda my bad. :/

Although I wish the CLC would have properly researched the consequences of the deprecation before going ahead and announcing it.