Where is the discussion on this PEP going to be? In this thread, or a new 
thread? Sorry for not having followed these closely enough to know. I'd like to 
point out that boost-histogram and xarray (at least) would love this as well, 
as we both (independently) came up with dict-in-index workarounds for missing 
keyword arguments. An argument for "why not a function call" could be added: 
function calls do not allow assignment, so `h[x=3] = ...` does not have a 
pretty functional replacement.

Also, maybe a mention as to why simply making a new set of magic methods, 
`__get_item__(self, *args, **kwargs)` for example, is not a valid option? The 
nice thing about that is the current oddity that you can't tell `[(1,2)]` from 
`[1, 2]` could also be fixed, along with avoiding all the special cases 
mentioned (which are pretty safe). Then a class that defines the new magic 
methods would use those instead of the old one, similar to 
getslice/setslice/delslice?
_______________________________________________
Python-ideas mailing list -- python-ideas@python.org
To unsubscribe send an email to python-ideas-le...@python.org
https://mail.python.org/mailman3/lists/python-ideas.python.org/
Message archived at 
https://mail.python.org/archives/list/python-ideas@python.org/message/7LFLWAS7SPIK3F4TSSMY53J53HJ7F643/
Code of Conduct: http://python.org/psf/codeofconduct/

Reply via email to