GHC compilation issue: How to work around bug #4374?