Refactor disassembly operand formatting to remove single-use functions.

This also cleans up an unintentionally duplicated case, and makes it more
obvious when such duplication occurs.
This commit is contained in:
Michael Hansen
2023-11-30 10:16:00 -08:00
parent 9c00554efb
commit b424ae8fd7
2 changed files with 105 additions and 108 deletions

View File

@@ -25,15 +25,6 @@ enum DisassemblyFlags {
const char* OpcodeName(int opcode);
int ByteToOpcode(int maj, int min, int opcode);
bool IsConstArg(int opcode);
bool IsNameArg(int opcode);
bool IsVarNameArg(int opcode);
bool IsCellArg(int opcode);
bool IsJumpAbsArg(int opcode);
bool IsJumpRelArg(int opcode);
bool IsJumpBackArg(int opcode);
bool IsCompareArg(int opcode);
}
void print_const(std::ostream& pyc_output, PycRef<PycObject> obj, PycModule* mod,