Created
March 16, 2017 02:48
-
-
Save Lazersmoke/ce82856da2c3782e9735d4617ceb99f5 to your computer and use it in GitHub Desktop.
MyClass a => a
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
class MyClass a where | |
value :: a | |
instance MyClass Char where | |
value = 'a' | |
instance MyClass Int where | |
value = 5 | |
something :: MyClass a => a | |
something = value |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment