[issue21406] Some socket constants are not enums
Charles-François Natali
report at bugs.python.org
Thu May 1 21:58:53 CEST 2014
Charles-François Natali added the comment:
To put it slightly differently:
AF_XXX constant actually whome belong to the same namespace, the
socket address family namespace.
So we put them all in AddressFamily Enum.
Now, for many constants defined in system header files, it's not so
clear, e.g. BTPROTO_RFCOMM, TIPC_ADDR_ID, SCM_CREDENTIALS: in which
Enum would you declare them?
I'm not saying it's a bad idea: it actually probably makes sense for
e.g. socket-level options (SO_REUSEADDR & Co), but it don't see any
generic classification scheme that would make sense for all of them.
----------
_______________________________________
Python tracker <report at bugs.python.org>
<http://bugs.python.org/issue21406>
_______________________________________
More information about the Python-bugs-list
mailing list