Repository navigation
Closed
Labels
bugSomething isn't workingSomething isn't working
Milestone
Description
Copilot-theorem fails to compile with GHC 8.8. From the travis build log https://travis-ci.org/github/Copilot-Language/copilot/jobs/769980874:
src/Copilot/Theorem/Kind2/Prover.hs:4:14: warning: [-Wtrustworthy-safe]
‘Copilot.Theorem.Kind2.Prover’ is marked as Trustworthy but has been inferred as safe!
|
4 | {-# LANGUAGE Trustworthy #-}
| ^^^^^^^^^^^
[32 of 33] Compiling Copilot.Theorem.Kind2 ( src/Copilot/Theorem/Kind2.hs, /home/travis/build/Copilot-Language/copilot/dist-newstyle/build/x86_64-linux/ghc-8.8.4/copilot-theorem-3.2.1/build/Copilot/Theorem/Kind2.o )
[33 of 33] Compiling Copilot.Theorem.What4 ( src/Copilot/Theorem/What4.hs, /home/travis/build/Copilot-Language/copilot/dist-newstyle/build/x86_64-linux/ghc-8.8.4/copilot-theorem-3.2.1/build/Copilot/Theorem/What4.o )
src/Copilot/Theorem/What4.hs:218:10: error:
• Expected kind ‘WT.BaseType -> *’,
but ‘WB.ExprSymFn t (WB.Expr t) (EmptyCtx ::> WT.BaseRealType
::> WT.BaseRealType)’ has kind ‘*’
• In the type ‘WB.ExprSymFn t (WB.Expr t) (EmptyCtx
::> WT.BaseRealType
::> WT.BaseRealType) WT.BaseRealType’
In the definition of data constructor ‘TransState’
In the data declaration for ‘TransState’
|
218 | pow :: WB.ExprSymFn t (WB.Expr t)
| ^^^^^^^^^^^^^^^^^^^^^^^^^^...
src/Copilot/Theorem/What4.hs:218:26: error:
• Expecting one more argument to ‘WB.Expr t’
Expected kind ‘Ctx WT.BaseType’,
but ‘WB.Expr t’ has kind ‘WT.BaseType -> *’
• In the second argument of ‘WB.ExprSymFn’, namely ‘(WB.Expr t)’
In the type ‘WB.ExprSymFn t (WB.Expr t) (EmptyCtx
::> WT.BaseRealType
::> WT.BaseRealType) WT.BaseRealType’
In the definition of data constructor ‘TransState’
|
218 | pow :: WB.ExprSymFn t (WB.Expr t)
| ^^^^^^^^^
src/Copilot/Theorem/What4.hs:219:11: error:
• Expected kind ‘WT.BaseType’,
but ‘EmptyCtx ::> WT.BaseRealType
::> WT.BaseRealType’ has kind ‘Ctx WT.BaseType’
• In the third argument of ‘WB.ExprSymFn’, namely
‘(EmptyCtx ::> WT.BaseRealType ::> WT.BaseRealType)’
In the type ‘WB.ExprSymFn t (WB.Expr t) (EmptyCtx
::> WT.BaseRealType
::> WT.BaseRealType) WT.BaseRealType’
In the definition of data constructor ‘TransState’
|
219 | (EmptyCtx ::> WT.BaseRealType ::> WT.BaseRealType)
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
src/Copilot/Theorem/What4.hs:222:11: error:
• Expected kind ‘WT.BaseType -> *’,
but ‘WB.ExprSymFn t (WB.Expr t) (EmptyCtx ::> WT.BaseRealType
::> WT.BaseRealType)’ has kind ‘*’
• In the type ‘WB.ExprSymFn t (WB.Expr t) (EmptyCtx
::> WT.BaseRealType
::> WT.BaseRealType) WT.BaseRealType’
In the definition of data constructor ‘TransState’
In the data declaration for ‘TransState’
|
222 | logb :: WB.ExprSymFn t (WB.Expr t)
| ^^^^^^^^^^^^^^^^^^^^^^^^^^...
src/Copilot/Theorem/What4.hs:222:27: error:
• Expecting one more argument to ‘WB.Expr t’
Expected kind ‘Ctx WT.BaseType’,
but ‘WB.Expr t’ has kind ‘WT.BaseType -> *’
• In the second argument of ‘WB.ExprSymFn’, namely ‘(WB.Expr t)’
In the type ‘WB.ExprSymFn t (WB.Expr t) (EmptyCtx
::> WT.BaseRealType
::> WT.BaseRealType) WT.BaseRealType’
In the definition of data constructor ‘TransState’
|
222 | logb :: WB.ExprSymFn t (WB.Expr t)
| ^^^^^^^^^
src/Copilot/Theorem/What4.hs:223:12: error:
• Expected kind ‘WT.BaseType’,
but ‘EmptyCtx ::> WT.BaseRealType
::> WT.BaseRealType’ has kind ‘Ctx WT.BaseType’
• In the third argument of ‘WB.ExprSymFn’, namely
‘(EmptyCtx ::> WT.BaseRealType ::> WT.BaseRealType)’
In the type ‘WB.ExprSymFn t (WB.Expr t) (EmptyCtx
::> WT.BaseRealType
::> WT.BaseRealType) WT.BaseRealType’
In the definition of data constructor ‘TransState’
|
223 | (EmptyCtx ::> WT.BaseRealType ::> WT.BaseRealType)
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
cabal: Failed to build copilot-theorem-3.2.1 (which is required by
copilot-3.2.1).
The command "cabal v2-build" exited with 1.
@benjaminselfridge Do you know why this is failing?
Metadata
Metadata
Assignees
Labels
bugSomething isn't workingSomething isn't working
Activity
ivanperez-keera commentedon May 8, 2021
By the way, with GHC 8.8 or GHC 8.6, copilot-theorem works with what4-1.0 but not with what4-1.1.
@benjaminselfridge Is this something we need to fix on our end or in what4?
[-]copilot-theorem fails to compile with GHC 8.8[/-][+]copilot-theorem won't install with GHC 8.8 and what4-1.1, but it does with GHC 8.8 and what4-1.0[/+][-]copilot-theorem won't install with GHC 8.8 and what4-1.1, but it does with GHC 8.8 and what4-1.0[/-][+]copilot-theorem won't install with GHC 8.8 and what4-1.1, but it does with what4-1.0[/+][-]copilot-theorem won't install with GHC 8.8 and what4-1.1, but it does with what4-1.0[/-][+]copilot-theorem won't install with what4-1.1, but it does with what4-1.0[/+]benjaminselfridge commentedon May 11, 2021
Hey all -- I'm taking a look at this right now. There were certainly some breaking changes with the new release of what4, so I think the right fix may be to simply add
what4 < 1.1to the version bounds. I will try and submit a patch within a day or two.benjaminselfridge commentedon May 11, 2021
#218
This should resolve it; let me know if you have any questions. The short version is, a few of the types changed in
what4-1.1and a few tweaks were required to adapt to those changes.Adds support for what4 1.1. Refs #216.