helix/helix-term
Michael Davis c262fe41ab
Consistently replace line-endings in paste/replace commands
Previously we replaced line-endings in pasted text to the document
line-ending for some values in paste commands. We missed the `repeat`
values in paste though and didn't do any replacement in the replace
command.

Along with this change I've refactored the replace command to avoid
intermediary collections. We previously eagerly collected the values
from the input register as a `Vec<String>` but we can avoid both of
those conversions and only allocate for the conversion to a `Tendril`.
We can also switch from `str::repeat` to a manual implementation to
avoid the intermediary conversion to a String - this avoids an extra
allocation in the common case (i.e. no count).

Fixes #12329
2024-12-25 11:38:44 -05:00
..
src Consistently replace line-endings in paste/replace commands 2024-12-25 11:38:44 -05:00
tests Fix continuing comment token for first line (#12215) 2024-12-10 13:24:34 -06:00
.gitignore
build.rs chore: clean up clippy lints (#11377) 2024-08-01 06:39:46 +09:00
Cargo.toml build(deps): bump the rust-dependencies group with 7 updates (#12327) 2024-12-25 10:05:50 -06:00