Warning: The install command is a part of the legacy v1 style of cabal usage. Please switch to using either the new project style and the new-install command or the legacy v1-install alias as new-style projects will become the default in the next version of cabal-install. Please file a bug if you cannot replicate a working v1- use case with the new-style commands. For more information, see: https://wiki.haskell.org/Cabal/NewBuild Resolving dependencies... Starting syb-0.7.1 Building syb-0.7.1 Completed syb-0.7.1 Starting algebraic-classes-0.9.4 Building algebraic-classes-0.9.4 Failed to install algebraic-classes-0.9.4 Build log ( /home/builder/.cabal/logs/ghc-8.6.3/algebraic-classes-0.9.4-BKOihomhW6s116uLQ3KW3.log ): cabal: Entering directory '/tmp/cabal-tmp-3140/algebraic-classes-0.9.4' Configuring algebraic-classes-0.9.4... Preprocessing library for algebraic-classes-0.9.4.. Building library for algebraic-classes-0.9.4.. [1 of 3] Compiling Data.Algebra.Internal ( Data/Algebra/Internal.hs, dist/build/Data/Algebra/Internal.o ) [2 of 3] Compiling Data.Algebra.TH ( Data/Algebra/TH.hs, dist/build/Data/Algebra/TH.o ) Data/Algebra/TH.hs:224:46: error: • Couldn't match expected type ‘Dec’ with actual type ‘TySynEqn -> Dec’ • Probable cause: ‘sigTFInst’ is applied to too few arguments In the expression: sigTFInst In the expression: [asInst, showInst, sigTFInst] In an equation for ‘signatureInstances’: signatureInstances nm s = [asInst, showInst, sigTFInst] where signature = ConT (signatureName s) sigTFInst = TySynInstD (TySynEqn Nothing (AppT (ConT ''Signature) (ConT nm)) signature) typeInst = TySynInstD (TySynEqn Nothing (AppT (ConT ''Class) signature) (ConT nm)) asClauses = [Clause [...] (NormalB (foldl (\ e arg -> AppE e (VarE arg)) (VarE fName) args)) [] | OperationTH fName opName ar _ _ <- operations s, let ...] .... | 224 | signatureInstances nm s = [asInst, showInst, sigTFInst] | ^^^^^^^^^ Data/Algebra/TH.hs:227:29: error: • Couldn't match expected type ‘Type -> Name’ with actual type ‘TySynEqn’ • The function ‘TySynEqn’ is applied to three arguments, but its type ‘[Type] -> Type -> TySynEqn’ has only two In the first argument of ‘TySynInstD’, namely ‘(TySynEqn Nothing (AppT (ConT ''Signature) (ConT nm)) signature)’ In the expression: TySynInstD (TySynEqn Nothing (AppT (ConT ''Signature) (ConT nm)) signature) | 227 | sigTFInst = TySynInstD (TySynEqn Nothing (AppT (ConT ''Signature) (ConT nm)) signature) | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ Data/Algebra/TH.hs:227:38: error: • Couldn't match expected type ‘[Type]’ with actual type ‘Maybe a0’ • In the first argument of ‘TySynEqn’, namely ‘Nothing’ In the first argument of ‘TySynInstD’, namely ‘(TySynEqn Nothing (AppT (ConT ''Signature) (ConT nm)) signature)’ In the expression: TySynInstD (TySynEqn Nothing (AppT (ConT ''Signature) (ConT nm)) signature) | 227 | sigTFInst = TySynInstD (TySynEqn Nothing (AppT (ConT ''Signature) (ConT nm)) signature) | ^^^^^^^ Data/Algebra/TH.hs:228:28: error: • Couldn't match expected type ‘Type -> Name’ with actual type ‘TySynEqn’ • The function ‘TySynEqn’ is applied to three arguments, but its type ‘[Type] -> Type -> TySynEqn’ has only two In the first argument of ‘TySynInstD’, namely ‘(TySynEqn Nothing (AppT (ConT ''Class) signature) (ConT nm))’ In the expression: TySynInstD (TySynEqn Nothing (AppT (ConT ''Class) signature) (ConT nm)) | 228 | typeInst = TySynInstD (TySynEqn Nothing (AppT (ConT ''Class) signature) (ConT nm)) | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ Data/Algebra/TH.hs:228:37: error: • Couldn't match expected type ‘[Type]’ with actual type ‘Maybe a1’ • In the first argument of ‘TySynEqn’, namely ‘Nothing’ In the first argument of ‘TySynInstD’, namely ‘(TySynEqn Nothing (AppT (ConT ''Class) signature) (ConT nm))’ In the expression: TySynInstD (TySynEqn Nothing (AppT (ConT ''Class) signature) (ConT nm)) | 228 | typeInst = TySynInstD (TySynEqn Nothing (AppT (ConT ''Class) signature) (ConT nm)) | ^^^^^^^ Data/Algebra/TH.hs:235:79: error: • Couldn't match expected type ‘Dec’ with actual type ‘TySynEqn -> Dec’ • Probable cause: ‘typeInst’ is applied to too few arguments In the expression: typeInst In the fourth argument of ‘InstanceD’, namely ‘[typeInst, FunD 'evaluate (asClauses ++ asScClauses)]’ In the expression: InstanceD Nothing [] (AppT (ConT ''AlgebraSignature) signature) [typeInst, FunD 'evaluate (asClauses ++ asScClauses)] | 235 | asInst = InstanceD Nothing [] (AppT (ConT ''AlgebraSignature) signature) [typeInst, FunD 'evaluate (asClauses ++ asScClauses)] | ^^^^^^^^ cabal: Leaving directory '/tmp/cabal-tmp-3140/algebraic-classes-0.9.4' cabal: Error: some packages failed to install: algebraic-classes-0.9.4-BKOihomhW6s116uLQ3KW3 failed during the building phase. The exception was: ExitFailure 1