Message119015
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. |
|
Date |
User |
Action |
Args |
2010-10-18 13:39:05 | casevh | set | recipients:
+ casevh, lemburg, tim.peters, loewis, skip.montanaro, georg.brandl, rhettinger, jimjjewett, mark.dickinson, belopolsky, pitrou, ked-tao, benjamin.peterson |
2010-10-18 13:39:05 | casevh | set | messageid: <1287409145.8.0.808802653028.issue9778@psf.upfronthosting.co.za> |
2010-10-18 13:39:03 | casevh | link | issue9778 messages |
2010-10-18 13:39:03 | casevh | create | |
|