This issue tracker has been migrated to GitHub, and is currently read-only.
For more information, see the GitHub FAQs in the Python's Developer Guide.

Author casevh
Recipients belopolsky, benjamin.peterson, casevh, georg.brandl, jimjjewett, ked-tao, lemburg, loewis, mark.dickinson, pitrou, rhettinger, skip.montanaro, tim.peters
Date 2010-10-18.13:39:03
SpamBayes Score 7.039449e-05
Marked as misclassified No
Message-id <1287409145.8.0.808802653028.issue9778@psf.upfronthosting.co.za>
In-reply-to
Content
Some quick comments on the latest patch.

1) I don't think you can remove the type cast used when comparing the hash value against -1 and -2. IIRC, GCC considers that undefined behavior.

2) In sysmodule.c, we need to use PyLong_FromSsize_t when storing _PyHASH_MODULUS.

3) In pyport.h, we need a better way to define _PyHASH_MODULUS. The existing "((1UL << _PyHASH_BITS) - 1)" fails when unsigned long is smaller than Py_ssize_t. "((1ULL << _PyHASH_BITS) - 1)" works on 64-bit Windows but is not a good solution for systems that don't have an unsigned long long type. I haven't thought of a better solution for one.
History
Date User Action Args
2010-10-18 13:39:05casevhsetrecipients: + casevh, lemburg, tim.peters, loewis, skip.montanaro, georg.brandl, rhettinger, jimjjewett, mark.dickinson, belopolsky, pitrou, ked-tao, benjamin.peterson
2010-10-18 13:39:05casevhsetmessageid: <1287409145.8.0.808802653028.issue9778@psf.upfronthosting.co.za>
2010-10-18 13:39:03casevhlinkissue9778 messages
2010-10-18 13:39:03casevhcreate