Julia: `parentindices` naming consistency

Created on 24 Jun 2018  路  6Comments  路  Source: JuliaLang/julia

Now that indices has been renamed to axes, should parentindices also be renamed to parentaxes?

parentaxes does seem slightly awkward by the way, sounds like a financial charge to dissuade people from using LISP.

All 6 comments

Can we just remove it entirely? Like parent, it has a pretense of being generic without actually being helpfully generic.

Even so, in this case, I think indices _is_ correct. It's specifically in reference to the indices you used to subset the parent. It is not the axes of the parent, nor would I describe the indices in something like the bitmask in @view A[A .> 0] or the linear indexing diagonal in @view A[1:size(A,1)+1:end] as axes.

Can we just remove it entirely? Like parent, it has a pretense of being generic without actually being helpfully generic.

Why does being generic matter? Some kind of stable interface would be very useful. Is there a guarantee that the name of the indices field of SubArray (actually, should that be indices?) won't be changed between minor versions?

Triage is full of apathy on this matter.

Haha, fair enough.

But seriously, we did discuss it and @mbauman was convinced that the current name is right.

Was this page helpful?
0 / 5 - 0 ratings

Related issues

ararslan picture ararslan  路  3Comments

TotalVerb picture TotalVerb  路  3Comments

dpsanders picture dpsanders  路  3Comments

sbromberger picture sbromberger  路  3Comments

StefanKarpinski picture StefanKarpinski  路  3Comments