Skip to main content

prev_from

Function prev_from 

Source
pub fn prev_from(matches: &[Match], from: usize) -> Option<usize>
Expand description

The last match starting strictly before from, wrapping to the end.

Callers navigating backwards pass the current match’s start, not the raw cursor: a cursor sitting inside a match would otherwise find that same match again and appear stuck.