forked from superfluid-finance/protocol-monorepo
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Adding Constant Flow Distribution Agreement etc. (superfluid-finance#…
…1017) - Major refactoring re agreement category, now with rigorous agreement laws as properties usable in quickchecks. - Constant FlowAgreement tested against the agreement laws. - Constant Flow Distribution Agreement modeled and tested against the agreement laws. - Some simplification of type value system. - Reorganize type modules into CoreTypes and SystemTypes.
- Loading branch information
Showing
62 changed files
with
2,816 additions
and
1,473 deletions.
There are no files selected for viewing
This file contains 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
This file contains 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
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -69,3 +69,4 @@ | |
# | ||
|
||
- ignore: {name: Use camelCase} | ||
- ignore: {name: Use newtype instead of data} |
This file contains 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
This file was deleted.
Oops, something went wrong.
This file contains 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
This file contains 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
This file contains 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
This file contains 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,21 @@ | ||
{-# LANGUAGE FunctionalDependencies #-} | ||
{-# LANGUAGE UndecidableSuperClasses #-} | ||
|
||
module Data.Type.Any where | ||
|
||
import Data.Kind (Constraint, Type) | ||
import Data.Proxy (Proxy) | ||
|
||
|
||
-- | ~AnyType~ ~a~ can hold wrap any instances of ~c~ constraint. | ||
-- | ||
-- Note: | ||
-- - It can be implemented with some flavor of existential type: https://wiki.haskell.org/Existential_type. | ||
-- | ||
class IsAnyTypeOf (a :: Type) (c :: Type -> Constraint) | a -> c where | ||
-- | Make a ~AnyType~ from a term that is of type that has ~c~ constraint. | ||
mkAny :: c e => Proxy a -> e -> a | ||
|
||
-- | Flip MPTC type params. | ||
class c a b => MPTC_Flip c b a | ||
instance c a b => MPTC_Flip c b a |
Oops, something went wrong.