Liking cljdoc? Tell your friends :D
Clojure only.

noahtheduke.splint.rules.lint.warn-on-reflection


warn-on-reflectionclj

Because we can't (or won't) check for interop, *warn-on-reflection* should be at the top of every file out of caution.

Examples:

bad

(ns foo.bar) (defn baz [a b] (+ a b))

good

(ns foo.bar) (set! warn-on-reflection true) (defn baz [a b] (+ a b))

Because we can't (or won't) check for interop, `*warn-on-reflection*` should
be at the top of every file out of caution.

Examples:

# bad
(ns foo.bar)
(defn baz [a b] (+ a b))

# good
(ns foo.bar)
(set! *warn-on-reflection* true)
(defn baz [a b] (+ a b))
sourceraw docstring

cljdoc is a website building & hosting documentation for Clojure/Script libraries

× close