[Python-ideas] namedtuple literals [Was: RE a new namedtuple]
chris.barker at noaa.gov
Fri Jul 28 20:27:23 EDT 2017
On Thu, Jul 27, 2017 at 7:42 PM, Ethan Furman <ethan at stoneleaf.us> wrote:
> How I get the point == 3? The first definition of an ntuple had the
> order as x, y, and since the proposal is only comparing field names (not
> order), this (y, x) ntuple ends up being reversed to how it was specified.
I'm not sure there ever was a "proposal" per se, but:
had better be a different type than:
but first we need to decide if we want an easy way to make an
namedtuple-like object or a SimpleNemaspace-like object....
but if you are going to allow indexing by integer, then order needs to be
part of the definition.
Christopher Barker, Ph.D.
Emergency Response Division
NOAA/NOS/OR&R (206) 526-6959 voice
7600 Sand Point Way NE (206) 526-6329 fax
Seattle, WA 98115 (206) 526-6317 main reception
Chris.Barker at noaa.gov
-------------- next part --------------
An HTML attachment was scrubbed...
More information about the Python-ideas