New submission from Jason R. Coombs <jar...@jaraco.com>: When trying to create a sub-subclass of a ctypes.Structure, the behavior is not as expected.
An executable example that describes the problem in detail and demonstrates the issue is available at http://paste.turbogears.org/paste/29555 and also attached. The failing behavior is near the beginning, following the description. Three unsuccessful workarounds follow. The expected behavior is found at the end, where a final workaround has been implemented. Can this behavior be improved in subsequent releases of ctypes? If not, can ctypes at least support the workaround natively (perhaps by providing a method in the Structure class that performs the workaround and can be called by a sub-subclass during __init__)? ---------- assignee: theller components: ctypes files: ctypes subclassing issues.py messages: 80457 nosy: jaraco, theller severity: normal status: open title: Structure sub-subclass does not initialize with base class positional arguments type: behavior versions: Python 2.5, Python 2.6, Python 3.0 Added file: http://bugs.python.org/file12845/ctypes subclassing issues.py _______________________________________ Python tracker <rep...@bugs.python.org> <http://bugs.python.org/issue5042> _______________________________________ _______________________________________________ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com