branch: elpa/rust-mode
commit 0bf2920e1d3fc5cd5f14b4e89d2535c1a39315cd
Author: Micah Chalmer <[email protected]>
Commit: Micah Chalmer <[email protected]>
Fix glitches with struct field aligned indents
---
rust-mode.el | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/rust-mode.el b/rust-mode.el
index 92b8524..e8cfd05 100644
--- a/rust-mode.el
+++ b/rust-mode.el
@@ -85,10 +85,10 @@
(not (looking-at "[[:space:]]*\\(?://.*\\)?$"))))
(+ 1 (current-column)))
;; Check for fields on the same line as the open curly brace:
- ((looking-at "{[[:blank:]]*[^}\n]*,[[:space:]]*$")
+ ((looking-at "{[[:space:]]*[^\n]*,[[:space:]]*$")
(progn
(forward-char)
- (forward-to-word 1)
+ (when (looking-at "[[:space:]]") (forward-to-word 1))
(current-column)))
(t (progn
(goto-char pt)