Skip to main content

normalize_range

Function normalize_range 

Source
pub const fn normalize_range(start: i64, stop: i64, len: i64) -> (i64, i64)
Expand description

Normalizes Redis index range supporting negative indices and wrapping. 归一化 Redis 索引范围(支持负数索引回环,未命中时 start > end)