Skip to content

Instantly share code, notes, and snippets.

@deque-blog
Last active November 30, 2017 14:37
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save deque-blog/413812015ac06c8365895522c55fa6c6 to your computer and use it in GitHub Desktop.
Save deque-blog/413812015ac06c8365895522c55fa6c6 to your computer and use it in GitHub Desktop.
-- Type alias in Idris (a function on types)
Cont : Type -> Type -> Type
Cont r a = (a -> r) -> r
parensCps : String -> Cont r String
parensCps s cont = cont ("(" ++ s ++ ")")
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment