Hacker Newsnew | past | comments | ask | show | jobs | submitlogin

What's the story on clojure and compile-time type safety ?

I've asked a clojure dev the other day about it and he told me this was experimental and not very common.



It's a dynamic language, if you must have static typing over Clojure it's not for you. (You can of course do a lot of other things at compile time via macros)


In all my time in Clojure I've never seen a project use compile-time type checking. core.typed [1] exists but I've never used it. Most people use either no type checking or if needed they'll judiciously apply something like schema [2] or spec [3].

[1]: https://github.com/clojure/core.typed

[2]: https://github.com/plumatic/schema

[3]: https://clojure.org/about/spec




Guidelines | FAQ | Lists | API | Security | Legal | Apply to YC | Contact

Search: