summaryrefslogtreecommitdiffstats
path: root/Lib/StringIO.py
diff options
context:
space:
mode:
Diffstat (limited to 'Lib/StringIO.py')
-rw-r--r--Lib/StringIO.py3
1 files changed, 1 insertions, 2 deletions
diff --git a/Lib/StringIO.py b/Lib/StringIO.py
index 5c463fb..1e5f254 100644
--- a/Lib/StringIO.py
+++ b/Lib/StringIO.py
@@ -72,8 +72,7 @@ class StringIO:
method is called repeatedly. This method returns the next input line,
or raises StopIteration when EOF is hit.
"""
- if self.closed:
- raise StopIteration
+ _complain_ifclosed(self.closed)
r = self.readline()
if not r:
raise StopIteration