From 697ad439064279637f791ef86061d9aa0d2845a0 Mon Sep 17 00:00:00 2001 From: tottoto Date: Sat, 15 Aug 2026 23:46:52 +0900 Subject: [PATCH] Use buffer local rustfmt switches --- rust-rustfmt.el | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/rust-rustfmt.el b/rust-rustfmt.el index adaeb0d..8694cd8 100644 --- a/rust-rustfmt.el +++ b/rust-rustfmt.el @@ -82,6 +82,7 @@ is to not modify this and rely on declarative configuration instead." (erase-buffer) (insert-buffer-substring buf) (let* ((tmpf (make-temp-file "rustfmt")) + (switches (buffer-local-value 'rust-rustfmt-switches buf)) (ret (apply #'call-process-region (point-min) (point-max) @@ -89,7 +90,7 @@ is to not modify this and rely on declarative configuration instead." t `(t ,tmpf) nil - rust-rustfmt-switches))) + switches))) (unwind-protect (cond ((zerop ret)