Message178605
| Author |
serhiy.storchaka |
| Recipients |
chris.jerdonek, esc24, ezio.melotti, mark.dickinson, serhiy.storchaka |
| Date |
2012年12月30日.19:36:27 |
| SpamBayes Score |
-1.0 |
| Marked as misclassified |
Yes |
| Message-id |
<1356896187.52.0.969813815554.issue16773@psf.upfronthosting.co.za> |
| In-reply-to |
| Content |
This is definitely non-trivial. 1-argument int() works with UserString because __int__() method is defined for UserString (as __float__(), as __complex__()). I.e. UserString looks as number-like for it. Unfortunately there is no way to make a class be string-like without inheriting it from str class. |
|