git clone https://github.com/yeputons/cabal-type-class-default-impl-rebuild.git
cd cabal-type-class-default-impl-rebuild
-
cabal v1-test
orcabal new-test
- Ensure that tests fail
- Update
src/MyClass.hs
by commenting the line withundefined
and uncommenting the line with10
-
cabal v1-test
orcabal new-test
- Ensure that tests still fail
-
cabal v1-clean
orcabal new-clean
-
cabal v1-test
orcabal new-test
- Ensure that tests now pass
See haskell/cabal#6045 and GHC Trac bug 15970