Skip to main content

offset_to_position

Function offset_to_position 

Source
pub fn offset_to_position(src: &str, offset: usize) -> (usize, usize)
Expand description

Convert a byte offset to an LSP (0-based line, 0-based character) position.