Skip to content

Instantly share code, notes, and snippets.

@krisleech
Created January 29, 2018 16:06
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 krisleech/eee9653a49e43e36577a7b7ee71ff079 to your computer and use it in GitHub Desktop.
Save krisleech/eee9653a49e43e36577a7b7ee71ff079 to your computer and use it in GitHub Desktop.
Clojure Typed
(t/ann stringy [t/Str -> t/Str]))
(defn stringy [a] (str a))
(stringy 1) ;; => runtime type error
(defn stringy [a] (symbol a)) ;; => compile time error
(t/ann person '{:name t/Str})
(def person { :name 1 }) ;; error
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment