mirror of
https://github.com/python/cpython.git
synced 2025-11-25 04:34:37 +00:00
Issue #20530: Argument Clinic's signature format has been revised again.
The new syntax is highly human readable while still preventing false positives. The syntax also extends Python syntax to denote "self" and positional-only parameters, allowing inspect.Signature objects to be totally accurate for all supported builtins in Python 3.4.
This commit is contained in:
parent
09f08fe248
commit
2623c8c23c
28 changed files with 825 additions and 327 deletions
|
|
@ -182,13 +182,13 @@ static PyMethodDef meth_methods[] = {
|
|||
static PyObject *
|
||||
meth_get__text_signature__(PyCFunctionObject *m, void *closure)
|
||||
{
|
||||
return _PyType_GetTextSignatureFromInternalDoc(m->m_ml->ml_doc);
|
||||
return _PyType_GetTextSignatureFromInternalDoc(m->m_ml->ml_name, m->m_ml->ml_doc);
|
||||
}
|
||||
|
||||
static PyObject *
|
||||
meth_get__doc__(PyCFunctionObject *m, void *closure)
|
||||
{
|
||||
return _PyType_GetDocFromInternalDoc(m->m_ml->ml_doc);
|
||||
return _PyType_GetDocFromInternalDoc(m->m_ml->ml_name, m->m_ml->ml_doc);
|
||||
}
|
||||
|
||||
static PyObject *
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue