mirror of https://github.com/helix-editor/helix
This code: let start = ensure_grapheme_boundary_next(text, text.byte_to_char(start)); let end = ensure_grapheme_boundary_next(text, text.byte_to_char(end)); Would convert byte to char index, but then internally immediately convert back to byte index, operate on it, then convert it to char index. This change reduces the amount of time spent in ensure_grapheme_boundary from 29% to 2%. |
||
---|---|---|
.. | ||
src | ||
.gitignore | ||
Cargo.toml |