Closed lspitzner closed 10 years ago
with these changes, it compiles in my linux setup with ghc 7.6.3, 7.8.2 and 7.8.3. a really minimal example application worked as well (although i am not sure if that really tested the MonadException code..). some proper testing adviced. The should be backward-compatible, as catch/mask were present in base for a long time (since base 4.3, if i read the docs correctly).
Doh! I haven't noticed this before opening PR #20. Perhaps this is a better solution…
@mietek heh i wondered if you had noticed :) what exactly do you refer to by "this"? your solution seems to be more thorough, but it breaks backward compatability? i do not know which one is better, really. personally i'd be happy with any patch that works with ghc 7.8
My solution decreases the amount of code to maintain in this package, but adds a dependency on exceptions
. This shouldn't break backwards compatibility, as the latest version of exceptions
still declares support for base-4.3
— however, I haven't tested anything but GHC 7.8.3.
It can be argued your patch is better, as it changes less, and does not add any dependencies. I'll let the maintainer decide.
Thanks guys for your patches and sorry @lspitzner for the long delay handling them. I actually prefer @mietek solutions because it deletes quite a lot of code from the hscurses package. I've merge @mietek commits to master with some additional support for exceptions < 0.6. Could you please test and let me know if everything is working as expected? Then I would upload a new version to hackage.
regarding @mietek 's patch: works with ghc 7.8.3 and 7.6.3 for me, too.
really minor issue: when switching ghc, needs clean. i.e.
cabal sandbox init
cabal install
cabal clean # important
cabal install -w $PATH_TO_GHC763
in theory that should work without the clean (right?)
but that probably won't ever affect anybody. with clean everything is fine.