diff options
Diffstat (limited to 'Lib/idlelib/PyShell.py')
-rwxr-xr-x | Lib/idlelib/PyShell.py | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/Lib/idlelib/PyShell.py b/Lib/idlelib/PyShell.py index 3c203d0..106e32b 100755 --- a/Lib/idlelib/PyShell.py +++ b/Lib/idlelib/PyShell.py @@ -1384,6 +1384,9 @@ class PseudoInputFile(PseudoFile): line = self._line_buffer or self.shell.readline() if size < 0: size = len(line) + eol = line.find('\n', 0, size) + if eol >= 0: + size = eol + 1 self._line_buffer = line[size:] return line[:size] |