Resolving dependencies... Downloading const-math-ghc-plugin-0.1.0.0... Configuring const-math-ghc-plugin-0.1.0.0... Building const-math-ghc-plugin-0.1.0.0... Preprocessing library const-math-ghc-plugin-0.1.0.0... [1 of 4] Compiling ConstMath.Rules ( ConstMath/Rules.hs, dist/build/ConstMath/Rules.o ) [2 of 4] Compiling ConstMath.Types ( ConstMath/Types.hs, dist/build/ConstMath/Types.o ) ConstMath/Types.hs:21:26: Warning: Defined but not used: `opts' [3 of 4] Compiling ConstMath.Pass ( ConstMath/Pass.hs, dist/build/ConstMath/Pass.o ) ConstMath/Pass.hs:27:62: Couldn't match expected type `[Char]' with actual type `SDoc -> String' In the return type of a call of `showSDoc' Probable cause: `showSDoc' is applied to too few arguments In the second argument of `(++)', namely `showSDoc (ppr b)' In the second argument of `(++)', namely `"Non-recursive binding named " ++ showSDoc (ppr b)' ConstMath/Pass.hs:27:72: Couldn't match expected type `DynFlags' with actual type `SDoc' In the return type of a call of `ppr' In the first argument of `showSDoc', namely `(ppr b)' In the second argument of `(++)', namely `showSDoc (ppr b)' ConstMath/Pass.hs:35:45: Couldn't match expected type `[Char]' with actual type `SDoc -> String' In the return type of a call of `showSDoc' Probable cause: `showSDoc' is applied to too few arguments In the second argument of `(++)', namely `showSDoc (ppr b)' In the second argument of `($)', namely `"Recursive binding " ++ showSDoc (ppr b)' ConstMath/Pass.hs:35:55: Couldn't match expected type `DynFlags' with actual type `SDoc' In the return type of a call of `ppr' In the first argument of `showSDoc', namely `(ppr b)' In the second argument of `(++)', namely `showSDoc (ppr b)' ConstMath/Pass.hs:40:39: Couldn't match expected type `[Char]' with actual type `SDoc -> String' In the return type of a call of `showSDoc' Probable cause: `showSDoc' is applied to too few arguments In the second argument of `(++)', namely `showSDoc (ppr t)' In the second argument of `(++)', namely `"Type " ++ showSDoc (ppr t)' ConstMath/Pass.hs:40:49: Couldn't match expected type `DynFlags' with actual type `SDoc' In the return type of a call of `ppr' In the first argument of `showSDoc', namely `(ppr t)' In the second argument of `(++)', namely `showSDoc (ppr t)' ConstMath/Pass.hs:48:38: Couldn't match expected type `[Char]' with actual type `SDoc -> String' In the return type of a call of `showSDoc' Probable cause: `showSDoc' is applied to too few arguments In the second argument of `(++)', namely `showSDoc (ppr lit)' In the second argument of `(++)', namely `"Lit " ++ showSDoc (ppr lit)' ConstMath/Pass.hs:48:48: Couldn't match expected type `DynFlags' with actual type `SDoc' In the return type of a call of `ppr' In the first argument of `showSDoc', namely `(ppr lit)' In the second argument of `(++)', namely `showSDoc (ppr lit)' ConstMath/Pass.hs:52:38: Couldn't match expected type `[Char]' with actual type `SDoc -> String' In the return type of a call of `showSDoc' Probable cause: `showSDoc' is applied to too few arguments In the second argument of `(++)', namely `showSDoc (ppr v)' In the second argument of `(++)', namely `"Var " ++ showSDoc (ppr v)' ConstMath/Pass.hs:52:48: Couldn't match expected type `DynFlags' with actual type `SDoc' In the return type of a call of `ppr' In the first argument of `showSDoc', namely `(ppr v)' In the second argument of `(++)', namely `showSDoc (ppr v)' ConstMath/Pass.hs:56:38: Couldn't match expected type `[Char]' with actual type `SDoc -> String' In the return type of a call of `showSDoc' Probable cause: `showSDoc' is applied to too few arguments In the second argument of `(++)', namely `showSDoc (ppr f)' In the second argument of `(++)', namely `"App " ++ showSDoc (ppr f)' ConstMath/Pass.hs:56:48: Couldn't match expected type `DynFlags' with actual type `SDoc' In the return type of a call of `ppr' In the first argument of `showSDoc', namely `(ppr f)' In the second argument of `(++)', namely `showSDoc (ppr f)' ConstMath/Pass.hs:201:34: Couldn't match type `SDoc -> String' with `[Char]' Expected type: DynFlags -> String Actual type: DynFlags -> SDoc -> String In the first argument of `(.)', namely `showSDoc' In the second argument of `(.)', namely `showSDoc . ppr' In the second argument of `(.)', namely `words . showSDoc . ppr' ConstMath/Pass.hs:201:45: Couldn't match type `SDoc' with `DynFlags' Expected type: CoreExpr -> DynFlags Actual type: CoreExpr -> SDoc In the second argument of `(.)', namely `ppr' In the second argument of `(.)', namely `showSDoc . ppr' In the second argument of `(.)', namely `words . showSDoc . ppr' Failed to install const-math-ghc-plugin-0.1.0.0 cabal: Error: some packages failed to install: const-math-ghc-plugin-0.1.0.0 failed during the building phase. The exception was: ExitFailure 1