Skip to content
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

Ignore unused-binding metadata on one of the arity in multi-arity function is not respected #2145

Closed
keychera opened this issue Jul 21, 2023 · 0 comments
Projects

Comments

@keychera
Copy link

version

2023.07.13

macro usage

no macros

platform

tested on native clj-kondo, MacOS

editor

also tested in Calvaa VSCode using 2023.06.02-SNAPSHOT

problem

ignore unused-binding metadata on one of the arity in multi-arity function is not respected

repro

file test-kondo.clj

(defn foo
  ([p1] (foo p1 "p2"))
  #_{:clj-kondo/ignore [:unused-binding]}
  ([p1 p2] (println p1 "not using p2")))
clj-kondo --lint test-kondo.clj
# =>
# test-kondo.clj:4:8: warning: unused binding p2
# linting took 21ms, errors: 0, warnings: 1

config

not a config issue

expected behavior

linting will produce zero warning

@borkdude borkdude added this to Needs triage in clj-kondo via automation Jul 21, 2023
@borkdude borkdude moved this from Needs triage to High priority (next release) in clj-kondo Jul 21, 2023
clj-kondo automation moved this from High priority (next release) to Done Jul 23, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
clj-kondo
  
Done
Development

No branches or pull requests

1 participant