Control.Category in base

Hi, I played with ghc head today. I saw that its base library contains Control.Category, and Control.Arrow uses that. (I also saw the discussion about it on this mailing list. There weren't any serious objections; the discussion was far from focused though [*], and I found that the patch was applied rather abruptly. [1]) Anyway, here's what I found trying to compile HXT: 1) Control.Arrow doesn't export (>>>) and (<<<) anymore. 2) All user defined instances of Control.Arrow.Arrow break. The first one is easily fixed in the base library. The second one is more annoying. The required changes to HXT aren't that big - my patch inserts 30 lines and deletes 10 - but it'll be harder to make it compatible between several ghc versions. So all in all I'm rather unhappy that this patch went in, because it breaks existing code and personally I see little gain from it. Personally I'd like to see that patch reverted. However I realize that my complaint comes rather late, so if we decide to keep the patch we have to fix the first issue above to minimize breakage of other packages. regards, Bertram [*] a lot of mails in the thread went off tangents, extending the proposal to refining the class hierarchy of arrows. For reference, the thread starts at http://www.haskell.org/pipermail/libraries/2007-October/008291.html [1] http://www.haskell.org/pipermail/libraries/2007-October/008496.html

On Sun, Nov 18, 2007 at 09:04:15AM +0100, Bertram Felgenhauer wrote:
Hi,
I played with ghc head today. I saw that its base library contains Control.Category, and Control.Arrow uses that. (I also saw the discussion about it on this mailing list. There weren't any serious objections; the discussion was far from focused though [*], and I found that the patch was applied rather abruptly. [1])
Anyway, here's what I found trying to compile HXT:
1) Control.Arrow doesn't export (>>>) and (<<<) anymore. 2) All user defined instances of Control.Arrow.Arrow break.
The first one is easily fixed in the base library.
The second one is more annoying. The required changes to HXT aren't that big - my patch inserts 30 lines and deletes 10 - but it'll be harder to make it compatible between several ghc versions.
So all in all I'm rather unhappy that this patch went in, because it breaks existing code and personally I see little gain from it.
Personally I'd like to see that patch reverted. However I realize that my complaint comes rather late, so if we decide to keep the patch we have to fix the first issue above to minimize breakage of other packages.
Simple-ish solution: Implement the class system extension proposal[1]. Stefan [1] http://haskell.org/haskellwiki/Class_system_extension_proposal Stefan

Stefan O'Rear wrote:
On Sun, Nov 18, 2007 at 09:04:15AM +0100, Bertram Felgenhauer wrote: [snip Control.Category problem]
2) All user defined instances of Control.Arrow.Arrow break.
Simple-ish solution: Implement the class system extension proposal[1].
Nice proposal, but that wouldn't help much here because (>>>) got renamed to (.) in the Category class, and you still need to provide an implementation for its 'id' function. Bertram
participants (2)
-
Bertram Felgenhauer
-
Stefan O'Rear