Message98173
| Author |
vstinner |
| Recipients |
doerwalter, eric.smith, ezio.melotti, vstinner |
| Date |
2010年01月23日.00:46:33 |
| SpamBayes Score |
0.0092486795 |
| Marked as misclassified |
No |
| Message-id |
<1264207595.48.0.194897709856.issue7267@psf.upfronthosting.co.za> |
| In-reply-to |
| Content |
('%c' % 255) == chr(255) == '\xff'
'%c' % 256 raise an "OverflowError: unsigned byte integer is greater than maximum" and chr(256) raise a "ValueError: chr() arg not in range(256)". I prefer the second error ;-)
str.format() should follow the same behaviour.
str is a byte string: it can be used to create a network packet or encode data into a byte stream. '%c' is useful for that, and str.format() should keep this nice feature. |
|
History
|
|---|
| Date |
User |
Action |
Args |
| 2010年01月23日 00:46:35 | vstinner | set | recipients:
+ vstinner, doerwalter, eric.smith, ezio.melotti |
| 2010年01月23日 00:46:35 | vstinner | set | messageid: <1264207595.48.0.194897709856.issue7267@psf.upfronthosting.co.za> |
| 2010年01月23日 00:46:34 | vstinner | link | issue7267 messages |
| 2010年01月23日 00:46:33 | vstinner | create |
|