[Python-Dev] String views (original) (raw)

Greg Ewing greg.ewing at canterbury.ac.nz
Mon Sep 5 02:42:59 CEST 2005


Steve Holden wrote:

Since Python strings can contain embedded NULs, doesn't that rather poo on the idea of passing pointers to their data to C functions as things stand?

If a Python function is clearly wrapping a C function, one doesn't expect to be able to pass strings with embedded NULs to it.

Just because a Python string can contain embedded NULs doesn't mean it makes sense to use such strings in all circumstances.

-- Greg Ewing, Computer Science Dept, +--------------------------------------+ University of Canterbury, | A citizen of NewZealandCorp, a | Christchurch, New Zealand | wholly-owned subsidiary of USA Inc. | greg.ewing at canterbury.ac.nz +--------------------------------------+



More information about the Python-Dev mailing list