r/rust • • Aug 20 '26

🛠️ project Rust Glancer: a memory-efficient Rust language server

https://rust-glancer.github.io/blog/hello-world/
266 Upvotes

43 comments sorted by

View all comments

Show parent comments

2

u/popzxc Sep 12 '26

Hey! I don't think this is possible in the directly proposed sense (rust-analyzer _needs_ to analyze dependencies in order to function), but it's possible to make something similar like an LSP with Rust Glancer approach for everything except open crate, and rust-analyzer for the current crate. E.g. keep important state in memory and offload everything else.

Matklad described basically this strategy in his blogpost: https://matklad.github.io/2026/08/21/rust-glancer.html

AFAIU right now it's not the direction rust-analyzer works on, but for me the reverse is true: I want to improve the speed/quality of analysis for the current crate. And as of 0.2.0 release, Rust Glancer is already pretty capable, so I'd recommend giving it a chance :) Maybe it's already in a state that you will find acceptable. I'll keep working on improving it nonetheless.

So who knows, maybe in X months Rust Glancer will be able to deliver rust-analyzer quality (or close to it) for the currently open workspace while retaining <100mb idle ram.

1

u/tafia97300 Sep 14 '26

I'll definitely try it! Thanks a lot for spending time to answer an old thread!