[New-bugs-announce] [issue32492] C Fast path for namedtuple's property/itemgetter pair

Raymond Hettinger report at bugs.python.org
Thu Jan 4 13:05:43 EST 2018


New submission from Raymond Hettinger <raymond.hettinger at gmail.com>:

Attribute access for named tuples can be made as fast as attribute access of instances of classes with slots.  All that is needed is a C subclass of property with it own __get__ that directly look's up the tuple field using PyTuple_GET_ITEM using an index stored in a C struct rather than as an integer object.

----------
components: Extension Modules
messages: 309477
nosy: rhettinger
priority: normal
severity: normal
status: open
title: C Fast path for namedtuple's property/itemgetter pair
versions: Python 3.7

_______________________________________
Python tracker <report at bugs.python.org>
<https://bugs.python.org/issue32492>
_______________________________________


More information about the New-bugs-announce mailing list