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

false positive type warning for (+ (byte 32) 1) #819

Closed
borkdude opened this issue Mar 27, 2020 · 0 comments
Closed

false positive type warning for (+ (byte 32) 1) #819

borkdude opened this issue Mar 27, 2020 · 0 comments

Comments

@borkdude
Copy link
Member

$ clj-kondo --lint -  <<< '(+ (byte 32) 1)'
<stdin>:1:4: error: Expected: number, received: byte.
linting took 70ms, errors: 1, warnings: 0

Workaround:

$ clj-kondo --lint - --config '{:linters {:type-mismatch {:namespaces {clojure.core {byte {:arities {1 {:ret #{:byte :number}}}}}}}}}' <<< '(+ (byte 32) 1)'
linting took 18ms, errors: 0, warnings: 0
@borkdude borkdude added this to Needs triage in clj-kondo via automation Mar 27, 2020
@borkdude borkdude moved this from Needs triage to High priority (next release) in clj-kondo Mar 27, 2020
borkdude added a commit that referenced this issue Mar 27, 2020
borkdude added a commit that referenced this issue Mar 27, 2020
@borkdude borkdude moved this from High priority (next release) to Next release in clj-kondo Mar 27, 2020
@borkdude borkdude closed this as completed Apr 5, 2020
clj-kondo automation moved this from Next release to Done Apr 5, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
clj-kondo
  
Done
Development

No branches or pull requests

1 participant