gh-105481: add flags to each instr in the opcode metadata table, to replace opcode.hasarg/hasname/hasconst (#105482)

This commit is contained in:
Irit Katriel 2023-06-13 21:42:03 +01:00 committed by GitHub
parent 2211454fe2
commit be2779c0cb
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
6 changed files with 681 additions and 625 deletions

View file

@ -219,6 +219,11 @@ GETITEM(PyObject *v, Py_ssize_t i) {
#define STACK_SHRINK(n) BASIC_STACKADJ(-(n))
#endif
/* Data access macros */
#define FRAME_CO_CONSTS (frame->f_code->co_consts)
#define FRAME_CO_NAMES (frame->f_code->co_names)
/* Local variable macros */
#define GETLOCAL(i) (frame->localsplus[i])