API for generic.arithmetic
- ()
by Konrad Hinsen
clojure-contrib is now deprecated
clojure-contrib is no longer being developed or maintained.
Rather than a single, monolithic, contributions library, Clojure now has
a set of separate libraries for each unit of functionality. The libraries
are in the Clojure GitHub organization at
https://github.com/clojure.
API documentation of the libraries can be found at
https://clojure.github.io.
If you're looking for a specific function or namespace from the old
clojure-contrib, see
"Where Did Clojure.Contrib Go".
Full namespace name:
clojure.contrib.generic.arithmetic
Overview
Generic arithmetic interface
This library defines generic versions of + - * / as multimethods
that can be defined for any type. The minimal required
implementations for a type are binary + and * plus unary - and /.
Everything else is derived from these automatically. Explicit
binary definitions for - and / can be provided for
efficiency reasons.
Public Variables and Functions
defmethod*
macro
This library, clojure-contrib, is deprecated. See here for more information.
Usage: (defmethod* ns name & args)
Define a method implementation for the multimethod name in namespace ns.
Required for implementing the division function from another namespace.
Source
qsym
macro
This library, clojure-contrib, is deprecated. See here for more information.
Usage: (qsym ns sym)
Create the qualified symbol corresponding to sym in namespace ns.
Required to access the division function from another namespace,
e.g. as (qsym clojure.contrib.generic.arithmetic /).
Source