Skip to content

Instantly share code, notes, and snippets.

@hanshoglund
Created November 5, 2012 03:13
Show Gist options
  • Save hanshoglund/4015125 to your computer and use it in GitHub Desktop.
Save hanshoglund/4015125 to your computer and use it in GitHub Desktop.
Type-fix combinators
with :: b -> a -> b
with x _ = x
fix :: a -> (a -> b) -> a
fix x _ = x
fix1 :: (a -> b) -> (a -> a) -> a -> b
fix1 x _ = x
int :: Int -> Int
int = id
str :: JsString -> JsString
str = id
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment