yarply
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
module Main where | |
data Foo = Foo | |
{ x :: String | |
, y :: String | |
, z :: String | |
} deriving (Show) | |
q = Foo "one" "two" "three" -- Foo {x = "one", y = "two", z = "three"} | |
q2 = q { x = "nine" } -- Foo {x = "nine", y = "two", z = "three"} | |
{-let og = Foo "Original"-} | |
{-let ns = setBar og "New School"-} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment