You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
To upvote this issue, give it a thumbs up. See this list for the most upvoted issues.
Is your feature request related to a problem? Please describe.
Nesting certain variadic functions/macros is redundant, and is usually confusing. We could catch this quite easily. E.g:
Describe the solution you'd like
When one of these functions/macros is nested within itself, raise a warning.
Additional context
From a cursory browse of clojure.core, this is a list of functions which could be included: **'++'andcompconcatevery-predlazy-catmaxmergeminorsome-fnstr
The redundant do and let linters are already present, but I guess a similar idea.
To upvote this issue, give it a thumbs up. See this list for the most upvoted issues.
Is your feature request related to a problem? Please describe.
Nesting certain variadic functions/macros is redundant, and is usually confusing. We could catch this quite easily. E.g:
Describe the solution you'd like
When one of these functions/macros is nested within itself, raise a warning.
Additional context
From a cursory browse of clojure.core, this is a list of functions which could be included:
*
*'
+
+'
and
comp
concat
every-pred
lazy-cat
max
merge
min
or
some-fn
str
The redundant
do
andlet
linters are already present, but I guess a similar idea.I knocked up the code for it here: https://github.com/tomdl89/clj-kondo/tree/redundant-nesting and can submit as a PR if there's interest.
The text was updated successfully, but these errors were encountered: