Message162324
| Author |
roger.serwy |
| Recipients |
Roy.Fox, ned.deily, python-dev, roger.serwy, terry.reedy |
| Date |
2012年06月05日.03:09:19 |
| SpamBayes Score |
-1.0 |
| Marked as misclassified |
Yes |
| Message-id |
<1338865761.05.0.581057142604.issue12510@psf.upfronthosting.co.za> |
| In-reply-to |
| Content |
The reoganization in i12510.test.diff will make back-porting to 2.7 slightly more difficult since old and new style classes exist. I do agree with your reasoning for re-factoring the code. (Also, as an extremely minor point, running reindent.py adjusts "pos = 70".)
I applied the patch and it works under 11.04 Ubuntu. All the tests pass and the behavior of the CallTip gives reasonable results when used interactively.
I did manage to find a corner-case where a CallTip should arise:
>>> class A:
def __init__(self, a=None):
print('init')
def __call__(self, b=None):
print('call')
>>> c = A(
Gives "(a=None)" as the call-tip. However, once the object is created, giving the __call__ argument doesn't work, i.e.
>>> c(
doesn't give a call-tip. This behavior is also the same without the patch.
I'll keep playing with the patch to see what else needs improving with CallTips. We might as well fix it completely. |
|
History
|
|---|
| Date |
User |
Action |
Args |
| 2012年06月05日 03:09:21 | roger.serwy | set | recipients:
+ roger.serwy, terry.reedy, ned.deily, python-dev, Roy.Fox |
| 2012年06月05日 03:09:21 | roger.serwy | set | messageid: <1338865761.05.0.581057142604.issue12510@psf.upfronthosting.co.za> |
| 2012年06月05日 03:09:20 | roger.serwy | link | issue12510 messages |
| 2012年06月05日 03:09:19 | roger.serwy | create |
|