Message96811
I doubt that buffers (including bytearray) are as useful in Python for
storing file names as they are in C.
Typically, when creating a buffer, you allocate some maximum size (in C:
MAXPATH or some such), and then you fill the buffer, and null-terminate.
In Python, you can't null-terminate; instead, the buffer must have the
right size already. So I wonder: where would you get a bytearray from
that has exactly the right size for a file name that you want to access
(and where do you get the file name from)?
If it is IAGNI, then: practicality beats purity - just because we
*could* support arbitrary byte areas, it doesn't mean we should. |
|
Date |
User |
Action |
Args |
2009-12-22 19:47:29 | loewis | set | recipients:
+ loewis, skrah, sh |
2009-12-22 19:47:28 | loewis | set | messageid: <1261511248.89.0.786271784374.issue7561@psf.upfronthosting.co.za> |
2009-12-22 19:47:27 | loewis | link | issue7561 messages |
2009-12-22 19:47:27 | loewis | create | |
|