mirror of
https://github.com/python/cpython.git
synced 2025-09-26 18:29:57 +00:00
Issue #8837: Remove "O?" format of PyArg_Parse*() functions. The format is no
used anymore and it was never documented.
This commit is contained in:
parent
c3acbc36d0
commit
33109a142b
2 changed files with 3 additions and 11 deletions
|
@ -12,6 +12,9 @@ What's New in Python 3.2 Alpha 1?
|
||||||
Core and Builtins
|
Core and Builtins
|
||||||
-----------------
|
-----------------
|
||||||
|
|
||||||
|
- Issue #8837: Remove "O?" format of PyArg_Parse*() functions. The format is no
|
||||||
|
used anymore and it was never documented.
|
||||||
|
|
||||||
- Issue #2844: Make int('42', n) consistently raise ValueError for
|
- Issue #2844: Make int('42', n) consistently raise ValueError for
|
||||||
invalid integers n (including n = -909).
|
invalid integers n (including n = -909).
|
||||||
|
|
||||||
|
|
|
@ -1292,17 +1292,6 @@ convertsimple(PyObject *arg, const char **p_format, va_list *p_va, int flags,
|
||||||
else
|
else
|
||||||
return converterr(type->tp_name, arg, msgbuf, bufsize);
|
return converterr(type->tp_name, arg, msgbuf, bufsize);
|
||||||
|
|
||||||
}
|
|
||||||
else if (*format == '?') {
|
|
||||||
inquiry pred = va_arg(*p_va, inquiry);
|
|
||||||
p = va_arg(*p_va, PyObject **);
|
|
||||||
format++;
|
|
||||||
if ((*pred)(arg))
|
|
||||||
*p = arg;
|
|
||||||
else
|
|
||||||
return converterr("(unspecified)",
|
|
||||||
arg, msgbuf, bufsize);
|
|
||||||
|
|
||||||
}
|
}
|
||||||
else if (*format == '&') {
|
else if (*format == '&') {
|
||||||
typedef int (*converter)(PyObject *, void *);
|
typedef int (*converter)(PyObject *, void *);
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue