This page is not created by, affiliated with, or supported by Slack Technologies, Inc.
2024-03-20
Channels
- # announcements (5)
- # aws (15)
- # babashka (12)
- # beginners (87)
- # calva (13)
- # cider (16)
- # clj-kondo (4)
- # clojure (22)
- # clojure-argentina (1)
- # clojure-europe (9)
- # clojure-houston (1)
- # clojure-nl (2)
- # clojure-norway (25)
- # clojure-uk (5)
- # clojurescript (12)
- # core-typed (37)
- # cursive (15)
- # datomic (40)
- # editors (8)
- # emacs (4)
- # events (1)
- # hyperfiddle (29)
- # keechma (8)
- # leiningen (6)
- # lsp (7)
- # malli (25)
- # off-topic (26)
- # pathom (10)
- # portal (3)
- # re-frame (22)
- # reitit (1)
- # releases (1)
- # ring (2)
- # shadow-cljs (18)
- # yamlscript (1)
https://github.com/typedclojure/typedclojure 1.2.1 has been released. https://github.com/typedclojure/typedclojure/blob/main/CHANGELOG.md#121-20240320
Please join #core-typed if you'd like to learn more.
Highlights (including 1.2.0):
• support for requiring-resolve
◦ e.g., (requiring-resolve 'fully-qualified/sym) : (t/Var (t/TypeOf fully-qualified/sym))
• improve support for passing keywords as functions to higher-order functions
◦ (map :a ...)
now infers accurately, bringing parity to existing support for (map #(:a %) ...)
• BREAKING: streamlined type arguments for mutable values
◦ combine input/output (co/contravariant) type arguments into one invariant
◦ e.g., old (Atom in out)
, new (Atom t)
.
◦ see changelog for migration instructions
• added handy type abbreviations like t/AnySeqable
<=> (t/Seqable t/Any)
• added full clj-kondo support for all public macros
◦ hooks distributed with jars
• add Java 21 annotation for java.util.SequencedCollection
• Introduce t/Instance
and t/Satisfies
as common supertypes for Classes/Protocols
◦ e.g., (Comparable Any) <: (t/Instance Comparable)
• enhance the return types of instance?
and satisfies?
to be more accurate
◦ e.g., (instance? Comparable x)
implies x : (Instance Comparable)
, not x : (Comparable Any)
• support annotating protocols without having to load them
I'm planning to try out typedclojure in a small CLJS project soon. Are some of these improvements also applicable to CLJS?
@U0479UCF48H Probably! I spent some time merging the backends of the implementations so a lot of the changes apply to both https://github.com/typedclojure/typedclojure/commit/e7dd70219b7259d5a1942a0b38d6e059c24404f4