On Tue, Jan 4, 2011 at 3:36 PM, Michael Foord firstname.lastname@example.org wrote:
The only examples I could find from a quick search (using the patch decorator from my mock module which is reasonably well used) patch __builtins__.open and raw_input.
So, that significantly weakens the argument that this optimization will break unit tests, since I am happy to promise never to optimize these builtins, and any other builtins intended for I/O.
Surely it will break somebody's code. That hasn't stopped us with other changes. The crux is whether it breaks significant amounts of code or code that would be really hard to write in another way.
-- --Guido van Rossum (python.org/~guido)