Skip to content

Instantly share code, notes, and snippets.

@supki
Created March 20, 2013 19:31
Show Gist options
  • Select an option

  • Save supki/5207714 to your computer and use it in GitHub Desktop.

Select an option

Save supki/5207714 to your computer and use it in GitHub Desktop.
Why contravariant type recursion is bad.
data Silly a = Silly (Silly a -> a)
herp :: Silly a -> a
herp (Silly f) = f (Silly f)
derp :: a
derp = herp (Silly herp)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment