/// Extension trait for `std::sync::RwLock` that recovers from lock poisoning
/// instead of panicking.
///
/// Lock poisoning occurs when a thread panics while holding a write lock.
/// In a download manager, a panic in one download task should not crash
/// the entire process — the data guarded by the lock may be partially
/// modified, but continuing is preferable to terminating.
///
/// Usage:
/// ```ignore
/// use crate::util::rwlock_ext::RwLockRecover;
/// let g = group.read().recover();
/// let mut g = group.write().recover();
/// ```
use RwLock;