gonna get this working in ghc 7.4 if it kills me