New submission from Erik Bray:

Although admittedly rare, I've on more than one occasion wanted to inspect the 
tp_flags of a given class.  It seems silly to me that although tp_flags is 
exposed to Python via type.__flags__, I then have to go rummaging around in 
Include/object.h in order to actually interpret the value of that attribute.

It would be nice, then, if the Py_TPFLAGS_* values were exposed as constants 
somewhere in Python (perhaps in the sys module)?

If it's agreed this is a good idea I'll gladly provide a patch if someone can 
point me toward where this would best live.

----------
components: Interpreter Core
messages: 249233
nosy: erik.bray
priority: normal
severity: normal
status: open
title: Expose Py_TPFLAGS_ values from Python
type: enhancement

_______________________________________
Python tracker <rep...@bugs.python.org>
<http://bugs.python.org/issue24945>
_______________________________________
_______________________________________________
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com

Reply via email to