Last active
August 29, 2015 14:03
-
-
Save lenary/6c0bceecc06d6e38f7e8 to your computer and use it in GitHub Desktop.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Idris> :l VerifiedNatLattice.idr | |
Type checking ./VerifiedNatLattice.idr | |
VerifiedNatLattice.idr:6:10: | |
When elaborating type of Prelude.Algebra.Nat instance of Prelude.Algebra.VerifiedBoundedJoinSemilattice, method boundedJoinSemilatticeBottomIsBottom: | |
Can't resolve type class BoundedJoinSemilattice B | |
Metavariables: Nat instance of Prelude.Algebra.VerifiedBoundedJoinSemilattice |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
instance VerifiedJoinSemilattice Nat where | |
joinSemilatticeJoinIsIdempotent = maximumIdempotent | |
joinSemilatticeJoinIsCommutative = maximumCommutative | |
joinSemilatticeJoinIsAssociative = maximumAssociative | |
instance VerifiedBoundedJoinSemilattice Nat where | |
boundedJoinSemilatticeBottomIsBottom = maximumZeroNLeft |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Relevant Prelude Code (from Prelude.Algebra): https://github.com/idris-lang/Idris-dev/blob/master/libs/prelude/Prelude/Algebra.idr#L179-L198
Though, it's worth pointing out, the type of
boundedJoinSemilatticeBottomIsBottom
should be:(because bottom is unitary, not nullary) see issue: idris-lang/Idris-dev#1384