[Python-Dev] str.lstrip bug?

lou xiao lox.xiao at gmail.com
Tue Mar 10 18:27:21 CET 2015


I find a bug in str.lstrip, when i call str.lstrip, i get this result.

tiny➜ ~ python
Python 2.7.5+ (default, Feb 27 2014, 19:37:08)
[GCC 4.8.1] on linux2
Type "help", "copyright", "credits" or "license" for more information.
>>> a='device_info'
>>> a.lstrip('device')
'_info'
>>> a.lstrip('device_')
'nfo'
>>>
tiny➜ ~ uname -a
Linux tinymint 3.11.0-12-generic #19-Ubuntu SMP Wed Oct 9 16:20:46 UTC 2013
x86_64 x86_64 x86_64 GNU/Linux
tiny➜ ~
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mail.python.org/pipermail/python-dev/attachments/20150311/36d2fad5/attachment.html>


More information about the Python-Dev mailing list