[Python-3000] Revised PEP for buffer protocol (original) (raw)

Josiah Carlson jcarlson at uci.edu
Wed Mar 21 00:16:25 CET 2007


Greg Ewing <greg.ewing at canterbury.ac.nz> wrote:

Nick Coghlan wrote: > I think the point is for there to be something in the standard library > or Python core that makes it easy for a consumer to copy the data to a > contiguous memory segment in the event the consumer can't directly > handle non-contiguous data It would be even more useful if the destination could be non-contiguous as well, but with a different stride. Then you could go from contiguous to non-contiguous, non-contiguous to contiguous, or repack between two different non-contiguous formats.

With writable views, presumably that would be a[w:x] = b[y:z], for any such operation (assuming compatible values, etc.).



More information about the Python-3000 mailing list