Skip to content

Commit 5a8c6ad

Browse files
Add __contains__ in dict_items
1 parent 8056604 commit 5a8c6ad

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

vm/src/builtins/dict.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1001,7 +1001,7 @@ impl PyDictItems {
10011001
return Ok(false);
10021002
}
10031003
let value = needle.fast_getitem(1);
1004-
let found = PyDict::getitem(zelf.dict().clone(), key, vm).unwrap();
1004+
let found = PyDict::getitem(zelf.dict().clone(), key, vm)?;
10051005
if !vm.identical_or_equal(&found, &value)? {
10061006
return Ok(false);
10071007
}

0 commit comments

Comments
 (0)