Merge pull request #2184 from davidhewitt/rust-1.59

rust: clippy fixes 1.59
This commit is contained in:
David Hewitt 2022-02-24 21:21:04 +00:00 committed by GitHub
commit 3d7080b0b5
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
1 changed files with 1 additions and 2 deletions

View File

@ -675,10 +675,9 @@ mod tests {
// Acquiring GIL for the second time should be safe - see #864 // Acquiring GIL for the second time should be safe - see #864
let gil = Python::acquire_gil(); let gil = Python::acquire_gil();
let py = gil.python(); let py = gil.python();
let obj;
let gil2 = Python::acquire_gil(); let gil2 = Python::acquire_gil();
obj = py.eval("object()", None, None).unwrap(); let obj = py.eval("object()", None, None).unwrap();
drop(gil2); drop(gil2);
// After gil2 drops, obj should still have a reference count of one // After gil2 drops, obj should still have a reference count of one