Kaydet (Commit) c5b6ab0b authored tarafından Guido van Rossum's avatar Guido van Rossum

Use input(), not our own fake raw input (in one place).

üst e625fd54
...@@ -28,11 +28,6 @@ _saferepr = _repr.repr ...@@ -28,11 +28,6 @@ _saferepr = _repr.repr
__all__ = ["run", "pm", "Pdb", "runeval", "runctx", "runcall", "set_trace", __all__ = ["run", "pm", "Pdb", "runeval", "runctx", "runcall", "set_trace",
"post_mortem", "help"] "post_mortem", "help"]
def raw_input(prompt):
sys.stdout.write(prompt)
sys.stdout.flush()
return sys.stdin.readline()
def find_function(funcname, filename): def find_function(funcname, filename):
cre = re.compile(r'def\s+%s\s*[(]' % re.escape(funcname)) cre = re.compile(r'def\s+%s\s*[(]' % re.escape(funcname))
try: try:
...@@ -543,7 +538,7 @@ class Pdb(bdb.Bdb, cmd.Cmd): ...@@ -543,7 +538,7 @@ class Pdb(bdb.Bdb, cmd.Cmd):
clear bpno bpno ... -> clear breakpoints by number""" clear bpno bpno ... -> clear breakpoints by number"""
if not arg: if not arg:
try: try:
reply = raw_input('Clear all breaks? ') reply = input('Clear all breaks? ')
except EOFError: except EOFError:
reply = 'no' reply = 'no'
reply = reply.strip().lower() reply = reply.strip().lower()
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment