regions
regions copied to clipboard
regions fails to compile under ghc 7.8.4
The build log in a clean sandbox is:
$ cabal install
Resolving dependencies...
Notice: installing into a sandbox located at
C:\Users\jophish\src\haskell\regions\.cabal-sandbox
Configuring stm-2.4.4...
Configuring transformers-0.4.2.0...
Building stm-2.4.4...
Building transformers-0.4.2.0...
Installed stm-2.4.4
Installed transformers-0.4.2.0
Configuring transformers-compat-0.4.0.4...
Building transformers-compat-0.4.0.4...
Installed transformers-compat-0.4.0.4
Configuring transformers-base-0.4.4...
Building transformers-base-0.4.4...
Installed transformers-base-0.4.4
Configuring monad-control-0.3.3.1...
Building monad-control-0.3.3.1...
Installed monad-control-0.3.3.1
Configuring regions-0.12...
Building regions-0.12...
Failed to install regions-0.12
Build log ( C:\Users\jophish\src\haskell\regions\.cabal-sandbox\logs\regions-0.12.log ):
Building regions-0.12...
Preprocessing library regions-0.12...
[1 of 4] Compiling Control.Monad.Trans.Region.Internal ( Control\Monad\Trans\Region\Internal.hs, dist\dist-sandbox-f55fe458\build\Control\Monad\Trans\Region\Internal.o )
Control\Monad\Trans\Region\Internal.hs:463:13:
Conflicting family instance declarations:
RegionStM (RegionT s parent)
-- Defined at Control\Monad\Trans\Region\Internal.hs:463:13
RegionStM
-- Defined at Control\Monad\Trans\Region\Internal.hs:475:13
cabal.exe: Error: some packages failed to install:
regions-0.12 failed during the building phase. The exception was:
ExitFailure 1
After speaking to the boffins on #Haskell it seems as though prior versions of GHC 7.6 was too lenient on what it accepted for type families, accepting invalid code.
Removing the instance (MonadBaseControl b m) => RegionBaseControl b m fixes this, although obviously the usefulness that provided is gone too.
I've fixed this in the RegionIOControl branch.
Super! Thanks @basvandijk! Any chance of an update to the version on Hackage?
Any chance of an update to the version on Hackage?
I first would like to try out these changes by basing safer-file-handles and regional-pointers on it. I can't promise when I get to that though...
I'm curious: Why has this package fallen by the wayside? Is there some problem with it that explains the lack of interest in keeping it alive? It seems like it would provide better static guarantees than resourcet, which a lot of people use.
Basically lack of time and other priorities. I'm flying to ZuriHac now so maybe I can spend some time there publishing a new version.