store/[org.clojure/clojure "1.8.0"] clj::clojure.core/inc

Official Documentation

Add notes
Arities
==================================================
   [x]

Docstring
==================================================
  Returns a number one greater than num. Does not auto-promote
  longs, will throw on overflow. See also: inc'

Source

(defn inc
  "Returns a number one greater than num. Does not auto-promote
  longs, will throw on overflow. See also: inc'"
  {:inline (fn [x] `(. clojure.lang.Numbers (~(if *unchecked-math* 'unchecked_inc 'inc) ~x)))
   :added "1.2"}
  [x] (. clojure.lang.Numbers (inc x)))

Example 1

Edit
(inc 1)
;; => 2

(inc 1.0)
;; => 2.0

(inc 1/2)
;; => 3/2

(inc -1)
;; => 0

Uses on crossclj