Description
Our indexing API has a mixture of terminology, such as getindex
, setindex!
, keys
and haskey
. This issue suggest simplifying some of this, as a continuation of #25057.
Basically, the idea is to replace our "key" terminology with "index" terminology, for consistency and to reduce the number of words used to describe the same thing. After discussion, it seems that "index" makes some sense for arrays and dictionaries, while "key" seems wrong for arrays, so we'd unify these in the direction of "index". We might consider the following:
Current | "Index" terminology |
---|---|
getindex |
getindex |
setindex! |
setindex! |
keys |
indices (in v1.0 not v0.7??) |
haskey |
hasindex (#25105) |
keytype |
indextype |
KeySet |
IndexSet |
@StefanKarpinski can you please clarify whether prior discussions count as triage or not (i.e. apply the correct label / milestone). In particular, the above table includes a couple extra (obvious) items for consistency. Thanks!