Last active
August 29, 2015 14:20
-
-
Save nrolland/9f40164ddfb11d1d94e4 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
module Bug where | |
type Adress = {city :: String} | |
type Person = {adress::Adress} | |
getCity :: Person -> String | |
getCity { adress = {city = c} } = c | |
billy = {adress: {city : "SFO" }} | |
b = getCity billy --OK | |
c = getCity billy --KO Error in binding group getCity, c: getCity may not be defined in the current scope |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment