<< Back to previous view

[CLJ-459] RFE: modify description of "assoc" Created: 14/Oct/10  Updated: 03/Sep/13  Resolved: 03/Sep/13

Status: Closed
Project: Clojure
Component/s: None
Affects Version/s: None
Fix Version/s: None

Type: Enhancement Priority: Major
Reporter: Anonymous Assignee: Unassigned
Resolution: Declined Votes: 0
Labels: None


The documentation for "assoc" in clojure.core should probably

(assoc vector index val)

<pre><code>(assoc vector index val & ivs)

in the usage line.

Comment by Assembla Importer [ 14/Oct/10 4:55 PM ]

Converted from http://www.assembla.com/spaces/clojure/tickets/459

Comment by Alex Miller [ 03/Sep/13 1:31 PM ]

assoc docstring talks about vectors. I don't think further changes are needed.

([map key val] [map key val & kvs])
  assoc[iate]. When applied to a map, returns a new map of the
    same (hashed/sorted) type, that contains the mapping of key(s) to
    val(s). When applied to a vector, returns a new vector that
    contains val at index. Note - index must be <= (count vector).
Generated at Fri Jan 19 23:42:57 CST 2018 using JIRA 4.4#649-r158309.