Skip to content

Instantly share code, notes, and snippets.

@manpages
Created June 23, 2015 23:16
Show Gist options
  • Save manpages/76dedcfbed4891842af2 to your computer and use it in GitHub Desktop.
Save manpages/76dedcfbed4891842af2 to your computer and use it in GitHub Desktop.
Let elimination example
{- let-elimination example -}
g x = (x, x - 1)
h = (42 +)
f = \x -> let (_,z) = g x in h z
f' = h . fst . g
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment