Skip to main content

timeout_counter

Function timeout_counter 

Source
pub fn timeout_counter(kind: BackendKind) -> &'static AtomicU64
Expand description

取某类后端的超时计数器。

内部是无 _ 分支的 match,不用 TIMEOUTS[kind as usize]: 加第 8 个变体时这里直接编译失败,而不是静默编译通过、运行期数错槽。