[Python-Dev] PEP 384 status (original) (raw)

Nick Coghlan ncoghlan at gmail.com
Wed Sep 1 00:33:45 CEST 2010


On Tue, Aug 31, 2010 at 2:15 PM, Mark Hammond <skippy.hammond at gmail.com> wrote:

It would be interesting to know how, in practice, these FILE pointers come to life.  In my experience they are generally obtained via fopen. If that is broadly true, then a middle-ground may be for Python to expose something like Pyfopen, Pyfclose and a PyFILE opaque "handle".  API elements which currently take a FILE * could be exposed using a PyFILE * in the ABI.  People who didn't care about this level of portability could continue to use the non-ABI FILE * functions, but people who do could use Pyfopen/Pyfclose in place of fopen/fclose but otherwise work as now.

No need for that - the Python-specific equivalent is our own I/O stack (and things like os.fdopen).

Cheers, Nick.

-- Nick Coghlan   |   ncoghlan at gmail.com   |   Brisbane, Australia



More information about the Python-Dev mailing list