summaryrefslogtreecommitdiffstats
path: root/Python
diff options
context:
space:
mode:
authorGuido van Rossum <guido@python.org>1996-09-07 15:55:27 (GMT)
committerGuido van Rossum <guido@python.org>1996-09-07 15:55:27 (GMT)
commitb072150d7f737728236ed819bc17383411e4eb86 (patch)
treecd1ee7ef24c7e82006b4bdb5d0d41901e073c0db /Python
parent87755a24c2df27f45a654b89b064606bc1905195 (diff)
downloadcpython-b072150d7f737728236ed819bc17383411e4eb86.zip
cpython-b072150d7f737728236ed819bc17383411e4eb86.tar.gz
cpython-b072150d7f737728236ed819bc17383411e4eb86.tar.bz2
Stupid bug: complex(x,y) would yield x+xj
Diffstat (limited to 'Python')
-rw-r--r--Python/bltinmodule.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/Python/bltinmodule.c b/Python/bltinmodule.c
index c337f1c..c1c3ed9 100644
--- a/Python/bltinmodule.c
+++ b/Python/bltinmodule.c
@@ -318,7 +318,7 @@ builtin_complex(self, args)
else if (is_complexobject(i))
ci = ((complexobject*)i)->cval;
else {
- tmp = (*nbr->nb_float)(r);
+ tmp = (*nbr->nb_float)(i);
if (tmp == NULL)
return NULL;
ci.real = getfloatvalue(tmp);