[New-bugs-announce] [issue38083] Minor improvements in asdl_c.py and Python-ast.c

Serhiy Storchaka report at bugs.python.org
Tue Sep 10 03:21:56 EDT 2019


New submission from Serhiy Storchaka <storchaka+cpython at gmail.com>:

* Use the const qualifier for constant C strings. This will save memory for their copy in a modifiable memory.
* Intern field and attribute names. This will save time, as comparing interned strings is faster.
* Temporary incref a borrowed reference to a list item. Arbitrary Python code can be executed when convert an item to C values. The list containing the item can be modified and the reference can became dead if not incref it.

----------
components: Interpreter Core
messages: 351582
nosy: eric.snow, serhiy.storchaka
priority: normal
severity: normal
status: open
title: Minor improvements in asdl_c.py and Python-ast.c
versions: Python 3.9

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


More information about the New-bugs-announce mailing list