Visitar URL original
Align psuedo ops to CPython 3.14.2 by youknowone · Pull Request #6846 · RustPython/RustPython · GitHub
Skip to content
Merged
Show file tree
Hide file tree
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Next Next commit
align HAVE_ARGUMENT
  • Loading branch information
youknowone committed Jan 24, 2026
commit 771650a012f0e277112fbcecd2017a6270567ba0
2 changes: 2 additions & 0 deletions crates/compiler-core/src/bytecode/instruction.rs
Original file line number Diff line number Diff line change
Expand Up @@ -426,6 +426,8 @@ impl InstructionMetadata for Instruction {
| Self::JumpForward { target: l }
| Self::PopJumpIfTrue { target: l }
| Self::PopJumpIfFalse { target: l }
| Self::PopJumpIfNone { target: l }
| Self::PopJumpIfNotNone { target: l }
| Self::ForIter { target: l }
| Self::Send { target: l } => Some(*l),
_ => None,
Expand Down
4 changes: 2 additions & 2 deletions crates/stdlib/src/_opcode.rs
Original file line number Diff line number Diff line change
Expand Up @@ -34,8 +34,8 @@ mod _opcode {
}

impl Opcode {
// https://github.com/python/cpython/blob/bcee1c322115c581da27600f2ae55e5439c027eb/Include/opcode_ids.h#L238
const HAVE_ARGUMENT: i32 = 44;
// https://github.com/python/cpython/blob/v3.14.2/Include/opcode_ids.h#L252
const HAVE_ARGUMENT: i32 = 43;

pub fn try_from_pyint(raw: PyIntRef, vm: &VirtualMachine) -> PyResult<Self> {
let instruction = raw
Expand Down