Meador Inge <mead...@gmail.com> added the comment: Module a few cosmetic changes (variable names and doc string tweaks), the patch looks good. Having a correct answer for `sys.getsizeof(struct.Struct('100B'))` is definitely better. Per the documentation for 'sys.getsizeof' [1]:
""" All built-in objects will return correct results, but this does not have to hold true for third-party extensions as it is implementation specific. """ If we consider extension modules as built-in objects, then this is a bug and should be fixed in 2.7, 3.2, and 3.3. If we don't, then the documentation for 'sys.getsizeof' should be adjusted and this patch should be applied after the default branch is unfrozen for enhancements. [1] http://docs.python.org/library/sys.html ---------- stage: -> patch review _______________________________________ Python tracker <rep...@bugs.python.org> <http://bugs.python.org/issue15402> _______________________________________ _______________________________________________ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com