Gregory P. Smith <[EMAIL PROTECTED]> added the comment: The asserts can go. I left them in figuring a crashing interpreter on a debug build in someones sandbox or on a buildbox would get more attention than a SystemError being raised. I doubt that is a worthy assumption on my part.
Both a crash and a SystemError are notable events. shall I get rid of the asserts? As for why i dislike signed size types... tons of reasons: * It wastes half the range of the integer. * It leads to security bugs. * on return values -1 and < 0 tests may be convenient to type but they could just as easily compare to a known value defined as a constant; all the things alexander belopolsky suggested. * sizes being passed -in- to a function never need to be negative meaning safe code requires extra checks like these. * sign extension of values going between registers of different sizes is needlessly expensive on some cpu architectures. use unsigned types whenever possible for the best code. anyways, I figure the Python C API is already set in stone using the signed types so its too late to "fix" it without causing headaches around the world. __________________________________ Tracker <[EMAIL PROTECTED]> <http://bugs.python.org/issue2587> __________________________________ _______________________________________________ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com