This page is not created by, affiliated with, or supported by Slack Technologies, Inc.
2024-03-12
Channels
- # beginners (12)
- # clj-kondo (3)
- # clojure-art (5)
- # clojure-gamedev (1)
- # clojure-norway (4)
- # clojure-poland (5)
- # clojurescript (1)
- # cursive (10)
- # emacs (1)
- # fulcro (2)
- # graalvm (3)
- # integrant (3)
- # lsp (4)
- # malli (8)
- # matrix (2)
- # off-topic (61)
- # practicalli (4)
- # releases (8)
- # shadow-cljs (34)
- # sql (6)
- # xtdb (8)
Hi. Cursive doesn't seem to apply the correct type hints when functions with type-hinted return value are used inside a threading macro without parentheses. For example, it's displaying a warning for:
(-> from-date
dates/to-instant
(.truncatedTo ChronoUnit/SECONDS) ; warns "clojure.lang.IFn.truncatedTo cannot be resolved"
dates/to-iso)
but not for
(-> from-date
(dates/to-instant)
(.truncatedTo ChronoUnit/SECONDS)
dates/to-iso)
and by the heartpulse emoji, i mean it's exciting!
especially with the interop enhancements upcoming in clojure 1.12, it should be much smoother to blend clojure with the java ecosystem.
the past year i had to explore the java.net.http
, java.time
& java.nio.file
packages and it was quite cumbersome without being able to rely on cursive's auto-completion and quick definition.
it meant i couldn't easily expect my colleagues to do such exploratory work because of this friction.
> the past year i had to explore the java.net.http
, java.time
& java.nio.file
packages and it was quite cumbersome without being able to rely on cursive's auto-completion and quick definition
Cursive does already suggest Java methods. What are you missing there?