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

Official Documentation

Add notes
Arities
==================================================
   [array]

Docstring
==================================================
  Returns a clone of the Java array. Works on arrays of known
  types.

Source

(defn aclone
  "Returns a clone of the Java array. Works on arrays of known
  types."
  {:inline (fn [a] `(. clojure.lang.RT (aclone ~a)))
   :added "1.0"}
  [array] (. clojure.lang.RT (aclone array)))

Example 1

Edit
;; create an Java integer array, then clone it
;; note that when you modify b, a remains the same
;; showing that b is not just a reference to a

(def a (int-array [1 2 3 4]))
;; => #'user/a

(def b (aclone a))
;; => #'user/b

(aset b 0 23)
;; => 23

(vec b)
;; => [23 2 3 4]

(vec a)
;; => [1 2 3 4]

Uses on crossclj