New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
core.match support #496
Comments
This should also support core matches or-syntax which currently causes arity error for keyword -> (let [x 4 y 6 z 9] |
My current plan is to just not lint the pattern part which is its own mini-language. |
Note: you can follow https://github.com/borkdude/clj-kondo/blob/master/doc/config.md#exclude-unresolved-symbols-from-being-reported to prevent those symbols from being reported for now. |
Is there something I could do now to prevent an error from the or-keyword? I get
from
using
|
@mikkosuonio Yes, there is a typo in your require spec: (ns match-test
{:clj-kondo/config '{:linters {:unresolved-symbol {:exclude [(cljs.core.match/match)]}
:invalid-arity {:skip-args [cljs.core.match/match]}}}}
(:require [cljs.core.match :as match]))
(let [x 4 y 6 z 9]
(match/match [x y z]
[(:or 1 2 3) _ ] :a0
[4 (:or 5 6 7) _] :a1
:else nil)) |
Thanks for pointing that out! Config for invalid-arity with skip-args seems to work fine! |
Merged part 1 to master now. Awaiting your feedback. You can grab a binary from CircleCI / appveyor or use the JVM version. |
And now the final part, part 2 is merged too! |
In the example below clj-kondo warns "unresolved symbol a".
The text was updated successfully, but these errors were encountered: