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 chris.jerdonek
Recipients chris.jerdonek, ezio.melotti, pitrou
Date 2012-09-25.17:01:29
SpamBayes Score -1.0
Marked as misclassified Yes
Message-id <1348592511.1.0.408086872965.issue16045@psf.upfronthosting.co.za>
In-reply-to
Content
Good thought.  Here is one data point:

$ pypy
Python 2.7.2 (341e1e3821fff77db3bb5cdb7a4851626298c44e, Jun 09 2012, 14:24:11)
[PyPy 1.9.0] on darwin
Type "help", "copyright", "credits" or "license" for more information.
>>>> int()
0
>>>> int(x='10', base=8)
8
>>>> int(x=5, base=10) 
Traceback (most recent call last):
  File "<console>", line 1, in <module>
TypeError: int() can't convert non-string with explicit base
>>>> int(base=6)
Traceback (most recent call last):
  File "<console>", line 1, in <module>
TypeError: int() can't convert non-string with explicit base
>>>> int(base='foo')
Traceback (most recent call last):
  File "<console>", line 1, in <module>
TypeError: expected integer, got str object

So it looks like "no x with given base" is where behavior differs.
History
Date User Action Args
2012-09-25 17:01:51chris.jerdoneksetrecipients: + chris.jerdonek, pitrou, ezio.melotti
2012-09-25 17:01:51chris.jerdoneksetmessageid: <1348592511.1.0.408086872965.issue16045@psf.upfronthosting.co.za>
2012-09-25 17:01:30chris.jerdoneklinkissue16045 messages
2012-09-25 17:01:29chris.jerdonekcreate