File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -258,6 +258,10 @@ mod key_cache {
258258 }
259259
260260 let slot_idx = fx_hash ( bytes) & ( CAP - 1 ) ;
261+ // `&raw mut` is the supported path to a `static mut`; the explicit
262+ // re-borrow keeps the field accesses readable. Clippy's `deref_addrof`
263+ // suggestion would re-introduce `static_mut_refs`.
264+ #[ allow( clippy:: deref_addrof) ]
261265 let slot = & mut * ( & raw mut SLOTS [ slot_idx] ) ;
262266
263267 if slot. len as usize == bytes. len ( )
@@ -431,8 +435,7 @@ where
431435 prev_key = Some ( key) ;
432436
433437 let ( key_ptr, key_hash) = unsafe { key_cache:: intern_key ( py, key) ? } ;
434- let key_bound: Bound < ' _ , PyAny > =
435- unsafe { Bound :: from_owned_ptr ( py, key_ptr) } ;
438+ let key_bound: Bound < ' _ , PyAny > = unsafe { Bound :: from_owned_ptr ( py, key_ptr) } ;
436439
437440 let value_py = decode_dag_cbor_to_pyobject ( py, r, depth + 1 ) ?;
438441
You can’t perform that action at this time.
0 commit comments