Skip to content

Commit a86abc1

Browse files
committed
inline c_1
1 parent 99c7be1 commit a86abc1

1 file changed

Lines changed: 1 addition & 3 deletions

File tree

Objects/complexobject.c

Lines changed: 1 addition & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -26,8 +26,6 @@ class complex "PyComplexObject *" "&PyComplex_Type"
2626

2727
/* elementary operations on complex numbers */
2828

29-
static Py_complex c_1 = {1., 0.};
30-
3129
Py_complex
3230
_Py_c_sum(Py_complex a, Py_complex b)
3331
{
@@ -347,7 +345,7 @@ _Py_c_pow(Py_complex a, Py_complex b)
347345
static Py_complex
348346
c_powu(Py_complex x, long n)
349347
{
350-
Py_complex p = x, r = n-- ? p : c_1;
348+
Py_complex p = x, r = n-- ? p : (Py_complex) {1., 0.};
351349
long mask = 1;
352350
assert(-1 <= n);
353351
assert(n < INT_EXP_CUTOFF);

0 commit comments

Comments
 (0)