This reverts the Haskell part of commit 326ca0f6, because these changes broke the 'scientific' build with GHC 7.4.2.