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 ocean-city
Recipients belopolsky, brian.curtin, ocean-city
Date 2010-12-08.19:21:40
SpamBayes Score 2.265397e-09
Marked as misclassified No
Message-id <1291836102.72.0.340931197912.issue10654@psf.upfronthosting.co.za>
In-reply-to
Content
This is shortest code to reproduce. But strange,
I can see TypeError on VC6(both Debug and Release)

E:\>e:\python-dev\py3k\pc\VC6\python.exe x.py
Traceback (most recent call last):
  File "x.py", line 10, in <module>
    a+i
TypeError: unsupported operand type(s) for +: 'SubclassDatetime' and 'int'

/////////////////////////////////////////////

from datetime import datetime

class SubclassDatetime(datetime):
    sub_var = 1

a = SubclassDatetime(2002, 3, 2, 17, 6)
# Add/sub ints or floats should be illegal
for i in 1, 1.0:
    a+i
History
Date User Action Args
2010-12-08 19:21:42ocean-citysetrecipients: + ocean-city, belopolsky, brian.curtin
2010-12-08 19:21:42ocean-citysetmessageid: <1291836102.72.0.340931197912.issue10654@psf.upfronthosting.co.za>
2010-12-08 19:21:40ocean-citylinkissue10654 messages
2010-12-08 19:21:40ocean-citycreate