reddit / emacs

Rust auto generate variable type

cog1tar3 · 2022-02-15 03:35
Does anyone know how to auto generate variable type for Rust in emacs. For example, when you type out the variable let msg = "something"; it will auto populate let msg: &str = "something"; Similar to the way that VS code does it.
ispinfx · 2022-02-15 05:02
`(setq lsp-rust-analyzer-server-display-inlay-hints t)`
alebrick · 2022-02-15 11:04
If you use `lsp-mode`, there should be a code action to do that.