Message160046
| Author |
rhettinger |
| Recipients |
benjamin.peterson, eric.smith, georg.brandl, larry, loewis, mark.dickinson, python-dev, rhettinger, serhiy.storchaka |
| Date |
2012年05月06日.00:15:34 |
| SpamBayes Score |
-1.0 |
| Marked as misclassified |
Yes |
| Message-id |
<1336263335.26.0.11458004972.issue14705@psf.upfronthosting.co.za> |
| In-reply-to |
| Content |
I would have expected a bool parse code to insist on a boolean, so that:
int x;
PyArg_ParseTupleAndKeywords(args, kwds, "p:func", &x);
would behave the same as:
PyObject *o;
int x;
PyArg_ParseTupleAndKeywords(args, kwds, "O!:func", &PyBool_Type, &o);
x = o == Py_True; |
|