Skip to content

Commit 1539105

Browse files
fix some GCC compilation warnings
1 parent 5e73b74 commit 1539105

File tree

1 file changed

+5
-5
lines changed

1 file changed

+5
-5
lines changed

Python/ceval.c

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -4075,7 +4075,6 @@ _PyEval_EvalFrameDefault(PyThreadState *tstate, PyFrameObject *f, int throwflag)
40754075
case TARGET(CALL_FUNCTION_ADAPTIVE): {
40764076
SpecializedCacheEntry *cache = GET_CACHE();
40774077
if (cache->adaptive.counter == 0) {
4078-
PyObject *callable = PEEK(cache->adaptive.original_oparg + 1);
40794078
next_instr--;
40804079
if (_Py_Specialize_CallFunction(stack_pointer, cache->adaptive.original_oparg, BUILTINS(), next_instr, cache) < 0) {
40814080
goto error;
@@ -5927,7 +5926,7 @@ call_function_builtin(PyThreadState *tstate,
59275926
#define MAYBE_TRACE(cfunc) if (use_tracing) {C_TRACE(x, cfunc);} else {x = cfunc;}
59285927

59295928
PyObject **pfunc = (*pp_stack) - oparg - 1;
5930-
PyObject *x, *w;
5929+
PyObject *x = NULL, *w;
59315930
PyObject **stack = (*pp_stack) - oparg;
59325931

59335932
PyObject *func = *pfunc; /* Only for tracing purposes */
@@ -5941,19 +5940,20 @@ call_function_builtin(PyThreadState *tstate,
59415940
break;
59425941
}
59435942
case _PYCFUNCTION_FAST: {
5944-
MAYBE_TRACE(((_PyCFunctionFast)cfunc)(self, stack, oparg));
5943+
MAYBE_TRACE(((_PyCFunctionFast)(void(*)(void))cfunc)(self, stack, oparg));
59455944
break;
59465945
}
59475946
case _PYCFUNCTION_FAST_WITH_KEYWORDS: {
5948-
MAYBE_TRACE(((_PyCFunctionFastWithKeywords)cfunc)(self, stack, oparg, 0));
5947+
MAYBE_TRACE(((_PyCFunctionFastWithKeywords)(void(*)(void))cfunc)(
5948+
self, stack, oparg, 0));
59495949
break;
59505950
}
59515951
case PYCFUNCTION_WITH_KEYWORDS: {
59525952
PyObject *args = _PyTuple_FromArray(stack, oparg);
59535953
if (args == NULL) {
59545954
break;
59555955
}
5956-
MAYBE_TRACE(((PyCFunctionWithKeywords)cfunc)(self, args, NULL));
5956+
MAYBE_TRACE(((PyCFunctionWithKeywords)(void(*)(void))cfunc)(self, args, NULL));
59575957
Py_DECREF(args);
59585958
break;
59595959
}

0 commit comments

Comments
 (0)