Mercurial > cpython-lru_cache-weakref
diff Lib/code.py @ 44421:f0e9c3d16766
Fix issue #1707. When raw_input() was removed, it was incorrectly replaced
with sys.stdin.readline(). I wonder how many other places are affected
by the same bug?
| author | Guido van Rossum <guido@python.org> |
|---|---|
| date | Wed, 02 Jan 2008 02:55:27 +0000 |
| parents | dd74e020a132 |
| children | 0db67153d25f |
line wrap: on
line diff
--- a/Lib/code.py Tue Jan 01 16:30:47 2008 +0000 +++ b/Lib/code.py Wed Jan 02 02:55:27 2008 +0000 @@ -253,13 +253,12 @@ The returned line does not include the trailing newline. When the user enters the EOF key sequence, EOFError is raised. - The base implementation uses sys.stdin.readline(); a subclass - may replace this with a different implementation. + The base implementation uses the built-in function + input(); a subclass may replace this with a different + implementation. """ - sys.stdout.write(prompt) - sys.stdout.flush() - return sys.stdin.readline() + return input(prompt)
