Skip to content

Commit 4f48198

Browse files
committed
Cleanup
1 parent e4b3141 commit 4f48198

File tree

4 files changed

+2
-21
lines changed

4 files changed

+2
-21
lines changed

Include/cpython/code.h

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -32,7 +32,6 @@ typedef uint16_t _Py_CODEUNIT;
3232
#define _Py_SET_OPCODE(word, opcode) \
3333
do { ((unsigned char *)&(word))[0] = (opcode); } while (0)
3434

35-
3635
// To avoid repeating ourselves in deepfreeze.py, all PyCodeObject members are
3736
// defined in this macro:
3837
#define _PyCode_DEF(SIZE) { \

Include/internal/pycore_ceval.h

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -25,7 +25,7 @@ struct _ceval_runtime_state;
2525

2626
#include "pycore_interp.h" // PyInterpreterState.eval_frame
2727
#include "pycore_pystate.h" // _PyThreadState_GET()
28-
#include "pycore_frame.h" // _PyThreadState_GET()
28+
2929

3030
extern void _Py_FinishPendingCalls(PyThreadState *tstate);
3131
extern void _PyEval_InitRuntimeState(struct _ceval_runtime_state *);

Objects/codeobject.c

Lines changed: 0 additions & 18 deletions
Original file line numberDiff line numberDiff line change
@@ -1401,36 +1401,18 @@ _PyCode_GetVarnames(PyCodeObject *co)
14011401
return get_localsplus_names(co, CO_FAST_LOCAL, co->co_nlocals);
14021402
}
14031403

1404-
PyObject *
1405-
PyCode_GetVarnames(PyCodeObject *code)
1406-
{
1407-
return _PyCode_GetVarnames(code);
1408-
}
1409-
14101404
PyObject *
14111405
_PyCode_GetCellvars(PyCodeObject *co)
14121406
{
14131407
return get_localsplus_names(co, CO_FAST_CELL, co->co_ncellvars);
14141408
}
14151409

1416-
PyObject *
1417-
PyCode_GetCellvars(PyCodeObject *code)
1418-
{
1419-
return _PyCode_GetCellvars(code);
1420-
}
1421-
14221410
PyObject *
14231411
_PyCode_GetFreevars(PyCodeObject *co)
14241412
{
14251413
return get_localsplus_names(co, CO_FAST_FREE, co->co_nfreevars);
14261414
}
14271415

1428-
PyObject *
1429-
PyCode_GetFreevars(PyCodeObject *code)
1430-
{
1431-
return _PyCode_GetFreevars(code);
1432-
}
1433-
14341416
static void
14351417
deopt_code(_Py_CODEUNIT *instructions, Py_ssize_t len)
14361418
{

Python/ceval.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4812,7 +4812,7 @@ _PyEval_EvalFrameDefault(PyThreadState *tstate, _PyInterpreterFrame *frame, int
48124812
function = PEEK(total_args + 1);
48134813
int positional_args = total_args - KWNAMES_LEN();
48144814
// Check if the call can be inlined or not
4815-
if (0 && Py_TYPE(function) == &PyFunction_Type && tstate->interp->eval_frame == NULL) {
4815+
if (Py_TYPE(function) == &PyFunction_Type && tstate->interp->eval_frame == NULL) {
48164816
int code_flags = ((PyCodeObject*)PyFunction_GET_CODE(function))->co_flags;
48174817
PyObject *locals = code_flags & CO_OPTIMIZED ? NULL : Py_NewRef(PyFunction_GET_GLOBALS(function));
48184818
STACK_SHRINK(total_args);

0 commit comments

Comments
 (0)