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

You should stop oversellling things. Spec is not a type system.


Just because you can't do a rigorous static analysis (which to certain degree is possible, check out Spectrum) it doesn't mean that Spec is not a type system.


That's misleading. Spec is a contract system. Read the page on the spec rationale: https://clojure.org/about/spec . It even mentions that spec is not a type system and that spec is similar to contracts in Racket, etc.

If we look at programming languages like Java, Typescript, C++, Haskell, etc., then we see that their type systems are completely different and have an entirely different purpose. Claiming to those users that spec is a type system, is just misleading them.


Semantics. Spec is very close to dependent types. "Entirely different purpose" is kinda vague. If the end result is the correctness of the program, the purpose is the same. If someone can perform Vivaldi's Four Seasons on Ukelele, it's cool. It doesn't make Ukelele less of an instrument.


So, spec is the ukulele in the vast domain of Type Systems?




Consider applying for YC's Winter 2026 batch! Applications are open till Nov 10

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

Search: