rust-lang / rust-mode

Emacs configuration for Rust
Apache License 2.0
1.1k stars 176 forks source link

Improve rust--format-fix-rustfmt-buffer #409

Closed sergv closed 2 years ago

sergv commented 3 years ago

I noticed that two loops can be merged into one. Also save-match-data will make this function not clobber global match data (not that anyone was suffering from that but nonetheless).

Upd: also noticed that *rustfmt* name can be configured but in error messages it'll stay the same. Fixed that too.

brotzeit commented 2 years ago

LGTM