summaryrefslogtreecommitdiffstats
path: root/Lib/UserString.py
diff options
context:
space:
mode:
authorGuido van Rossum <guido@python.org>2000-04-11 15:38:46 (GMT)
committerGuido van Rossum <guido@python.org>2000-04-11 15:38:46 (GMT)
commit86662914be20e1f008132647a82cdeb9506f13c5 (patch)
tree3e4d9998f3fbf1b027eb38014388d479997c250f /Lib/UserString.py
parent3afba7644b481eb7ef6baf02fad42a185b0f008e (diff)
downloadcpython-86662914be20e1f008132647a82cdeb9506f13c5.zip
cpython-86662914be20e1f008132647a82cdeb9506f13c5.tar.gz
cpython-86662914be20e1f008132647a82cdeb9506f13c5.tar.bz2
Marc-Andre Lemburg:
The maxsplit functionality in .splitlines() was replaced by the keepends functionality which allows keeping the line end markers together with the string.
Diffstat (limited to 'Lib/UserString.py')
-rwxr-xr-xLib/UserString.py2
1 files changed, 1 insertions, 1 deletions
diff --git a/Lib/UserString.py b/Lib/UserString.py
index c2c2bed..528065e 100755
--- a/Lib/UserString.py
+++ b/Lib/UserString.py
@@ -96,7 +96,7 @@ class UserString:
def rstrip(self): return self.__class__(self.data.rstrip())
def split(self, sep=None, maxsplit=-1):
return self.data.split(sep, maxsplit)
- def splitlines(self, maxsplit=-1): return self.data.splitlines(maxsplit)
+ def splitlines(self, keepends=0): return self.data.splitlines(keepends)
def startswith(self, prefix, start=0, end=sys.maxint):
return self.data.startswith(prefix, start, end)
def strip(self): return self.__class__(self.data.strip())