Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

How safe is it to update base?

Tags:

haskell

cabal

On ubuntu I currently have haskell-platform 2011.2.0.1.2 installed, and I am currently working on some code where it would be very nice to have Control.Concurrent.Chan be an instance of Eq. Unfortunately, in base-4.3.1.0, which is the one I have installed, it is not, but in base-4.4.0.0 Chan is an instance of Eq.

Would it be possible to update base, maybe by sandboxing it with cabal-dev or any other method, in a way that would not break too many packages?

like image 810
HaskellElephant Avatar asked Apr 07 '12 16:04

HaskellElephant


1 Answers

No, you should never upgrade base. It's one of the boot packages — the packages that GHC itself needs to build, and ships with — and upgrading them will lead to Very Bad Things™. (Here's a full list of boot packages; everything with a - in the tag column is one. Don't upgrade these!)

Indeed, cabal-install's cabal upgrade feature was removed precisely because it had a nasty tendency to upgrade boot packages.

Not only is it a boot package, but being such core functionality, it's pretty much inherently tied to a specific GHC version. Your best option is to install the corresponding newer version of GHC in a local directory.

like image 135
ehird Avatar answered Oct 20 '22 15:10

ehird