This issue tracker has been migrated to GitHub, and is currently read-only.
For more information, see the GitHub FAQs in the Python's Developer Guide.

Author rbcollins
Recipients rbcollins
Date 2007-10-10.23:41:28
SpamBayes Score 0.28453872
Marked as misclassified No
Message-id <1192059689.8.0.690640268578.issue1259@psf.upfronthosting.co.za>
In-reply-to
Content
Python 2.5.1 (r251:54863, May  2 2007, 16:56:35) 
[GCC 4.1.2 (Ubuntu 4.1.2-0ubuntu4)] on linux2
Type "help", "copyright", "credits" or "license" for more information.
>>> 'asd'.find('s', None, None)
Traceback (most recent call last):
  File "<stdin>", line 1, in <module>
TypeError: slice indices must be integers or None or have an __index__
method
>>> 'asd'.rfind('s', None, None)
Traceback (most recent call last):
  File "<stdin>", line 1, in <module>
TypeError: slice indices must be integers or None or have an __index__
method
>>> # Note that this works, at the price of a memory copy,
>>> # and on large strings that is undesirable.
>>> 'asd'[None:None].find('s')
1
>>> 'asd'[None:None].rfind('s')
1
>>>
History
Date User Action Args
2007-10-10 23:41:30rbcollinssetspambayes_score: 0.284539 -> 0.28453872
recipients: + rbcollins
2007-10-10 23:41:29rbcollinssetspambayes_score: 0.284539 -> 0.284539
messageid: <1192059689.8.0.690640268578.issue1259@psf.upfronthosting.co.za>
2007-10-10 23:41:29rbcollinslinkissue1259 messages
2007-10-10 23:41:29rbcollinscreate