Message126413
| Author |
ron_adam |
| Recipients |
avdd, bquinlan, r.david.murray, ron_adam |
| Date |
2011年01月17日.17:19:25 |
| SpamBayes Score |
4.559792e-05 |
| Marked as misclassified |
No |
| Message-id |
<1295284771.49.0.150634408768.issue10918@psf.upfronthosting.co.za> |
| In-reply-to |
| Content |
Why is this surprising?
>>> def foo(c, c=None):
... pass
...
File "<stdin>", line 1
SyntaxError: duplicate argument 'c' in function definition
In the previous examples, it finds the duplicate at run time instead of compile time due to not being able to determine the contents of kwargs at compile time. It's just a bug in your code if you do it, and it should raise an exception as it does. |
|
History
|
|---|
| Date |
User |
Action |
Args |
| 2011年01月17日 17:19:31 | ron_adam | set | recipients:
+ ron_adam, bquinlan, r.david.murray, avdd |
| 2011年01月17日 17:19:31 | ron_adam | set | messageid: <1295284771.49.0.150634408768.issue10918@psf.upfronthosting.co.za> |
| 2011年01月17日 17:19:25 | ron_adam | link | issue10918 messages |
| 2011年01月17日 17:19:25 | ron_adam | create |
|