Created
March 24, 2016 12:28
-
-
Save wchargin/261f658b7088e617948d to your computer and use it in GitHub Desktop.
convenience functors for easily defining equality instances
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
functor MagicEq (eqtype t) : EQUAL where type t = t = | |
struct | |
type t = t | |
val equal : t * t -> bool = op = | |
end | |
functor MagicPairOfEq (structure E1 : EQUAL | |
structure E2 : EQUAL) : PAIR_OF_EQUAL = | |
struct | |
structure E1 = E1 | |
structure E2 = E2 | |
end |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment