core-typed

2025-05-25T21:29:06.672509Z

Curious how core.typed compares to what is being worked on in the Elixir world? https://hexdocs.pm/elixir/main/gradual-set-theoretic-types.html Are they based around different ideas, or similar?

2025-05-26T01:17:28.318829Z

Assuming it follows from the rest of Castagna's work, both have similar goals in terms of giving the programmer expressive types to specify programs that manipulate data. However, the core semantic subtyping algorithm is much more subtle and powerful than Typed Clojure's subtyping.

2025-05-26T01:17:36.573269Z

Typed Clojure has no gradual typing.

2025-05-26T01:23:42.516769Z

Tho this application of "gradual typing" seems much different to what I'm used to.

2025-05-26T03:42:52.111949Z

We have unions, intersections, and negations, but use a much more naive subtyping algorithm (presumably).

2025-05-26T03:45:50.010899Z

Semantic subtyping maps types onto sets and then use set membership to determine compatible types. Typed Clojure tries to normalize types into a normal form and then subtyping mostly deals with those cases.