Skip to content

Commit ec481b6

Browse files
committed
use PY_UINT32_T instead of uint32_t
1 parent f6dcb21 commit ec481b6

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

Modules/_randommodule.c

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -313,7 +313,7 @@ random_setstate(RandomObject *self, PyObject *state)
313313
int i;
314314
unsigned long element;
315315
long index;
316-
uint32_t new_state[N];
316+
PY_UINT32_T new_state[N];
317317

318318
if (!PyTuple_Check(state)) {
319319
PyErr_SetString(PyExc_TypeError,
@@ -330,7 +330,7 @@ random_setstate(RandomObject *self, PyObject *state)
330330
element = PyLong_AsUnsignedLong(PyTuple_GET_ITEM(state, i));
331331
if (element == (unsigned long)-1 && PyErr_Occurred())
332332
return NULL;
333-
new_state[i] = (uint32_t)element;
333+
new_state[i] = (PY_UINT32_T)element;
334334
}
335335

336336
index = PyLong_AsLong(PyTuple_GET_ITEM(state, i));

0 commit comments

Comments
 (0)