Fork me on GitHub
#clj-kondo
<
2021-07-01
>
Juλian (he/him)09:07:26

how can I make clj-kondo aware of Quil's defsketch macro? it always flags the following symbol as "unresolved symbol" error

borkdude09:07:19

@julian608 depending on what the macro does, you can use :lint-as. e.g. {:lint-as {foo.bar/defsketch clojure.core/def}}

borkdude09:07:16

some examples would help (the docs only give docs but no examples)

borkdude09:07:46

I see:

(defsketch my-sketch
  :size [500 500]
  :draw draw))

borkdude09:07:07

I think for this one you'll probably want to use clj-kondo.lint-as/def-catch-all

Juλian (he/him)09:07:12

thanks! linting as def turns it into info "unused public var", and def-catch-all makes it accepted... will try it like that

borkdude14:07:14

Can clj-kondo also fix the things it reports? No, it only analyzes and reports, but clojure-lsp can use that data to fix :)

🎉 6
clojure-lsp 2