Kaydet (Commit) c7745d4b authored tarafından Fred Drake's avatar Fred Drake

InteractiveInterpreter.showsyntaxerror():

    When replacing the exception object, be sure we stuff the new value
    in sys.last_value (which we already did for the original value).
üst a7cc69e0
......@@ -137,6 +137,7 @@ class InteractiveInterpreter:
except:
# If that failed, assume SyntaxError is a string
value = msg, (filename, lineno, offset, line)
sys.last_value = value
list = traceback.format_exception_only(type, value)
map(self.write, list)
......
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