aset-long

clojure.core

  • (aset-long array idx val)
  • (aset-long array idx idx2 & idxv)
Sets the value at the index/indices. Works on arrays of long. Returns val.

1 Example top

  • ;; create an array of 10 longs and set one of the values to 31415
    
    user=> (def ls (long-array 10))
    #'user/ls
    user=> (vec ls)
    [0 0 0 0 0 0 0 0 0 0]
    user=> (aset-long ls 3 31415)
    31415
    user=> (vec ls)
    [0 0 0 31415 0 0 0 0 0 0]
    user=>
Log in to add / edit an example.

See Also top

Log in to add a see also.

Plus_12x12 Minus_12x12 Source clojure/core.clj:3489 top

(def-aset
  ^{:doc "Sets the value at the index/indices. Works on arrays of long. Returns val."
    :added "1.0"}
  aset-long setLong long)
Vars in clojure.core/aset-long:
Used in 0 other vars

Comments top

No comments for aset-long. Log in to add a comment.