mirror of
https://github.com/johndoe6345789/typthon.git
synced 2026-04-24 13:45:05 +00:00
Fix more missed Py_ patterns - opcode, thread, exception
Fixed additional patterns: - _PyOpcode_* → _TyOpcode_* (all opcode metadata) - _PyUOpName → _TyUOpName - _PyFunction_* → _TyFunction_* - _PyListIterObject → _TyListIterObject - _Py_T_OBJECT → _Ty_T_OBJECT - Py_BEGIN_ALLOW_THREADS, Py_END_ALLOW_THREADS → Ty_* - PyDoc_STRVAR, PyDoc_STR → TyDoc_* - PyInterpreterState, PyThread_*, PyTime_t → Ty* - PyStructSequence_* → TyStructSequence_* - PyLockStatus → TyLockStatus - PyVarObject_HEAD_INIT → TyVarObject_HEAD_INIT - PyBaseExceptionObject → TyBaseExceptionObject - Fixed _PyExc_ → _TyExc_ in exception macros Build is progressing further. Co-authored-by: johndoe6345789 <224850594+johndoe6345789@users.noreply.github.com>
This commit is contained in:
@@ -33,7 +33,7 @@
|
||||
#include <stddef.h>
|
||||
|
||||
#ifdef Ty_DEBUG
|
||||
extern const char *_PyUOpName(int index);
|
||||
extern const char *_TyUOpName(int index);
|
||||
extern void _PyUOpPrint(const _PyUOpInstruction *uop);
|
||||
static const char *const DEBUG_ENV = "PYTHON_OPT_DEBUG";
|
||||
static inline int get_lltrace(void) {
|
||||
@@ -145,7 +145,7 @@ static int
|
||||
remove_globals(_PyInterpreterFrame *frame, _PyUOpInstruction *buffer,
|
||||
int buffer_size, _PyBloomFilter *dependencies)
|
||||
{
|
||||
PyInterpreterState *interp = _TyInterpreterState_GET();
|
||||
TyInterpreterState *interp = _TyInterpreterState_GET();
|
||||
TyObject *builtins = frame->f_builtins;
|
||||
if (builtins != interp->builtins) {
|
||||
OPT_STAT_INC(remove_globals_builtins_changed);
|
||||
@@ -156,7 +156,7 @@ remove_globals(_PyInterpreterFrame *frame, _PyUOpInstruction *buffer,
|
||||
assert(TyFunction_Check(function));
|
||||
assert(function->func_builtins == builtins);
|
||||
assert(function->func_globals == globals);
|
||||
uint32_t function_version = _PyFunction_GetVersionForCurrentState(function);
|
||||
uint32_t function_version = _TyFunction_GetVersionForCurrentState(function);
|
||||
/* In order to treat globals as constants, we need to
|
||||
* know that the globals dict is the one we expected, and
|
||||
* that it hasn't changed
|
||||
|
||||
Reference in New Issue
Block a user