regions icon indicating copy to clipboard operation
regions copied to clipboard

regions fails to compile under ghc 7.8.4

Open expipiplus1 opened this issue 10 years ago • 6 comments

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

expipiplus1 avatar Feb 23 '15 21:02 expipiplus1

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.

expipiplus1 avatar Feb 23 '15 22:02 expipiplus1

I've fixed this in the RegionIOControl branch.

basvandijk avatar Feb 24 '15 11:02 basvandijk

Super! Thanks @basvandijk! Any chance of an update to the version on Hackage?

expipiplus1 avatar Feb 24 '15 11:02 expipiplus1

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...

basvandijk avatar Feb 24 '15 11:02 basvandijk

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.

Rotaerk avatar Jun 05 '18 22:06 Rotaerk

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.

basvandijk avatar Jun 07 '18 13:06 basvandijk