[Python-Dev] PEP 296 - The Buffer Problem

Scott Gilbert xscottg@yahoo.com
Thu, 25 Jul 2002 10:00:03 -0700 (PDT)


--- Thomas Heller <thomas.heller@ion-tof.com> wrote:
>
> *I* have no use for this at the moment.
> I was just trying to understand the (let's call it) large
> byte-array support in Scott's proposal on 64-bit platforms,
> and how to program portably on 64-bit and 32-bit platforms.
> 
> Assuming we have a large enough byte array
>   unsigned char *ptr;
> and want to use it in C, for example get a certain byte:
> 
>   unsigned char *mybyte = ptr[my_index];
> 
> What should the type of my_index be? IIRC, Scott proposed LONG_LONG,
> but wouldn't this be a paint on 32-bit platforms?
> 

Ok, now that I understand where you're coming from.  If nobody has an
objection or can point to a supported platform where it won't work, I'll
switch it to size_t.










__________________________________________________
Do You Yahoo!?
Yahoo! Health - Feel better, live better
http://health.yahoo.com