homepage

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 cmcqueen1975
Recipients cmcqueen1975, dtorp, josiahcarlson, mark.dickinson, tim.peters
Date 2010年01月26日.01:06:39
SpamBayes Score 0.00033885657
Marked as misclassified No
Message-id <1264468002.06.0.0627214993591.issue1205239@psf.upfronthosting.co.za>
In-reply-to
Content
Just for the record... here is a relevant use case...
I'm working on some code for calculating CRCs, and hope to support any CRC width, including CRC-5. This involves, among the calculations:
 crc >> (crc_width - 8)
The complete expression is:
 crc = table[((crc >> (crc_width - 8)) ^ data_byte) & 0xFF] ^ (crc << 8)
where crc_width is typically 32 or 16, but in the case of CRC-5 would be 5.
I think the calculation would work fine for all cases, if only Python allowed me to right-shift with a negative number. But now I'll have to handle the two cases separately.
History
Date User Action Args
2010年01月26日 01:06:42cmcqueen1975setrecipients: + cmcqueen1975, tim.peters, josiahcarlson, mark.dickinson, dtorp
2010年01月26日 01:06:42cmcqueen1975setmessageid: <1264468002.06.0.0627214993591.issue1205239@psf.upfronthosting.co.za>
2010年01月26日 01:06:40cmcqueen1975linkissue1205239 messages
2010年01月26日 01:06:39cmcqueen1975create

AltStyle によって変換されたページ (->オリジナル) /