Skip to content
Merged
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
Prev Previous commit
Next Next commit
Fix CallAllocAndEnterInit to use LocalsPlus stack API
  • Loading branch information
youknowone committed Mar 4, 2026
commit 927269c0c15bb48eca32cf4d213803ba801f94b6
5 changes: 2 additions & 3 deletions crates/vm/src/frame.rs
Original file line number Diff line number Diff line change
Expand Up @@ -4311,9 +4311,8 @@ impl ExecutingFrame<'_> {
let cached_version = self.code.instructions.read_cache_u32(cache_base + 1);
let nargs: u32 = arg.into();
let callable = self.nth_value(nargs + 1);
let stack = &self.state.stack;
let stack_len = stack.len();
let self_or_null_is_some = stack[stack_len - nargs as usize - 1].is_some();
let stack_len = self.localsplus.stack_len();
let self_or_null_is_some = self.localsplus.stack_index(stack_len - nargs as usize - 1).is_some();
if !self_or_null_is_some
&& cached_version != 0
&& let Some(cls) = callable.downcast_ref::<PyType>()
Expand Down