summaryrefslogtreecommitdiff
path: root/Lib/code.py
diff options
context:
space:
mode:
authorNeal Norwitz <nnorwitz@gmail.com>2006-03-17 06:49:51 +0000
committerNeal Norwitz <nnorwitz@gmail.com>2006-03-17 06:49:51 +0000
commitce96f69d69a6020c780145c89a17a8391b63624b (patch)
tree7325a9bfaddf191e49910532df1fa4210c335196 /Lib/code.py
parent9e2b9665ae9f94a07da54156c48e2cd411a23746 (diff)
downloadcpython-git-ce96f69d69a6020c780145c89a17a8391b63624b.tar.gz
Get rid of a bunch more raw_input references
Diffstat (limited to 'Lib/code.py')
-rw-r--r--Lib/code.py10
1 files changed, 6 insertions, 4 deletions
diff --git a/Lib/code.py b/Lib/code.py
index 6bdc658add..b67009b93b 100644
--- a/Lib/code.py
+++ b/Lib/code.py
@@ -269,12 +269,14 @@ class InteractiveConsole(InteractiveInterpreter):
The returned line does not include the trailing newline.
When the user enters the EOF key sequence, EOFError is raised.
- The base implementation uses the built-in function
- raw_input(); a subclass may replace this with a different
- implementation.
+ The base implementation uses sys.stdin.readline(); a subclass
+ may replace this with a different implementation.
"""
- return raw_input(prompt)
+ sys.stdout.write(prompt)
+ sys.stdout.flush()
+ return sys.stdin.readline()
+
def interact(banner=None, readfunc=None, local=None):