Fork me on GitHub
#clj-kondo
<
2019-12-20
>
pez20:12:42

Does clj-kondo have some way to tell a binding vector from other vectors? Or is it based on a list of known macros?

pez20:12:51

Asking for a friend. 😃

borkdude20:12:13

@pez What's the background of this question?

borkdude21:12:10

How does this relate to linting?

pez21:12:45

Not at all. I just notice that clj-kondo seems to know when I am not using bindings, and that paredit feature would neeed similar knowledge, so wondered about the mechanincs of this magic.

borkdude21:12:31

Ah. Well, clj-kondo has special rules for analyzing several built-in vars/forms, it can't magically know otherwise

borkdude21:12:48

There is no metadata or anything to go by

borkdude21:12:14

so if you encounter a name like clojure.core/let you know the first one is a binding vector

pez21:12:17

Cool. I thought as much, but good to know for sure.

borkdude21:12:37

Most of this code is in clj-kondo.impl.analyzer.clj