Prefer utf-8 over utf-32
Utf-8 support has been around for a while as an unstable feature but
utf-32 is fairly new. A bunch of LS (like rust-analyzer) added this in
a pinch, but it's pretty broken right now. The performance overhead is
not very large (still a lot better than utf-16). We can switch back
once the ecosystem has matured.
commita48d1a4abc0d23d6bc3cfda714d87b9fa4484da8
authorPascal Kuthe <pascal.kuthe@semimod.de>
dateThu 30 Mar 2023, 18:27 (4 years ago)
parent7a69c40
helix-lsp/src/client.rs+1−1
@@ -538,8 +538,8 @@ impl Client {
538538 }),
539539 general: Some(lsp::GeneralClientCapabilities {
540540 position_encodings: Some(vec![
541− PositionEncodingKind::UTF32,
542541 PositionEncodingKind::UTF8,
542+ PositionEncodingKind::UTF32,
543543 PositionEncodingKind::UTF16,
544544 ]),
545545 ..Default::default()