mirror of
https://github.com/python/cpython.git
synced 2025-07-12 13:55:34 +00:00
Again perhaps the end of [#460020] bug or feature: unicode() and subclasses.
Inhibited complex unary plus optimization when applied to a complex subtype. Added PyComplex_CheckExact macro. Some comments and minor code fiddling.
This commit is contained in:
parent
1140cb2b9e
commit
2400fa4ad1
4 changed files with 45 additions and 12 deletions
|
@ -659,7 +659,7 @@ float_subtype_new(PyTypeObject *type, PyObject *args, PyObject *kwds)
|
|||
tmp = float_new(&PyFloat_Type, args, kwds);
|
||||
if (tmp == NULL)
|
||||
return NULL;
|
||||
assert(PyFloat_Check(tmp));
|
||||
assert(PyFloat_CheckExact(tmp));
|
||||
new = type->tp_alloc(type, 0);
|
||||
if (new == NULL)
|
||||
return NULL;
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue