(>defn name
doc-string?
attr-map?
([params*] gspec prepost-map? body?)
+
attr-map?)
(>defn name doc-string? attr-map? [params*] gspec prepost-map? body?)
Like defn, but requires a (nilable) gspec definition and generates
additional s/fdef
, generative tests, instrumentation code, an
fspec-based stub, and/or tracing code, depending on the configuration
metadata and the existence of a valid gspec and non-nil body.
Like defn, but requires a (nilable) gspec definition and generates additional `s/fdef`, generative tests, instrumentation code, an fspec-based stub, and/or tracing code, depending on the configuration metadata and the existence of a valid gspec and non-nil body.
(>defn- name
doc-string?
attr-map?
([params*] gspec prepost-map? body?)
+
attr-map?)
(>defn- name doc-string? attr-map? [params*] gspec prepost-map? body?)
Like defn-, but requires a (nilable) gspec definition and generates
additional s/fdef
, generative tests, instrumentation code, an
fspec-based stub, and/or tracing code, depending on the configuration
metadata and the existence of a valid gspec and non-nil body.
Like defn-, but requires a (nilable) gspec definition and generates additional `s/fdef`, generative tests, instrumentation code, an fspec-based stub, and/or tracing code, depending on the configuration metadata and the existence of a valid gspec and non-nil body.
(>fdef name [params*] gspec)
(>fdef name ([params*] gspec) +)
Defines an fspec using gspec syntax – pretty much a >defn
without the body.
name
can be a symbol or a qualified keyword, depending on whether the
fspec is meant to be registered as a top-level fspec (=> s/fdef fn-sym
...) or used in other specs (=> s/def ::spec-keyword (s/fspec ...)).
When defining global fspecs, instrumentation can be directly enabled by
setting the ^::g/instrument
or ^::g/outstrument
metadata on the symbol.
Defines an fspec using gspec syntax – pretty much a `>defn` without the body. `name` can be a symbol or a qualified keyword, depending on whether the fspec is meant to be registered as a top-level fspec (=> s/fdef fn-sym ...) or used in other specs (=> s/def ::spec-keyword (s/fspec ...)). When defining global fspecs, instrumentation can be directly enabled by setting the `^::g/instrument` or `^::g/outstrument` metadata on the symbol.
(clean-defn op forms)
This removes the gspec and returns a clean defn for use in production builds.
This removes the gspec and returns a clean defn for use in production builds.
cljdoc is a website building & hosting documentation for Clojure/Script libraries
× close