[Python-3000] bytes & Py_TPFLAGS_BASETYPE
mathieu.fenniak at gmail.com
Sun Sep 16 17:46:18 CEST 2007
I'd like to be able to derive from the bytes type, but this currently
isn't possible due to it missing the Py_TPFLAGS_BASETYPE. A comment
next to the flags indicates that this class is "sealed / final". I
tried to search this list for some information on this, but I
couldn't find any relevant posts. Why is this type "sealed"?
I've experimented by adding the basetype flag to the type (with a
recent svn checkout). Python's test suite continues to run without
any errors after this change. My own project's test suite works
flawlessly with a bytes derived type, as well. I expected to
encounter some error or difficulty that would explain why this type
wasn't usable as a base type, but it seems to work great.
More information about the Python-3000