[issue7865] io close() swallowing exceptions

Antoine Pitrou report at bugs.python.org
Thu Apr 29 22:16:16 CEST 2010


Antoine Pitrou <pitrou at free.fr> added the comment:

> But maybe this is not so important, as these are programming errors
> anyway.

Agreed :)

> One thing I'm still wondering : why couldn't we obtain these C
> extension by cythonizing _pyio ? Are there features that cython lacks, 
> or optimization considerations I'm not aware of ? Cython-generated
> extensions seem soooo easier to maintain...

Several reasons:
- we don't want to depend on an external tool such as cython; the interpreter and its most critical modules just need a C compiler and a reasonably standard C library
- the language cython implements is not Python: it is both a superset and (more annoyingly) a subset of Python
- cython will not allow us, I think, to do as many optimizations as we do in the C version of the io library; the algorithms used are not the same as in the Python version, since raw C allows some much more efficient constructs (especially for handling memory buffers)

----------

_______________________________________
Python tracker <report at bugs.python.org>
<http://bugs.python.org/issue7865>
_______________________________________


More information about the Python-bugs-list mailing list