Convert a byte offset range to an LSP `Range`. Returns a `Range` with both endpoints converted from byte offsets to `Position` (line/character).
(content: &str, start: usize, end: usize)
| 474 | /// Returns a `Range` with both endpoints converted from byte offsets |
| 475 | /// to `Position` (line/character). |
| 476 | pub(crate) fn byte_range_to_lsp_range(content: &str, start: usize, end: usize) -> Range { |
| 477 | let start_pos = offset_to_position(content, start); |
| 478 | let end_pos = offset_to_position(content, end); |
| 479 | Range { |
| 480 | start: start_pos, |
| 481 | end: end_pos, |
| 482 | } |
| 483 | } |
| 484 | |
| 485 | /// Strip trailing PHP visibility/modifier keywords from a string. |
| 486 | /// |
no test coverage detected