From b971c6dd1c9356d4ace237c7e173dcbcb454a992 Mon Sep 17 00:00:00 2001 From: mrBliss Date: Sun, 24 Apr 2016 12:23:18 +0200 Subject: Fix #151 When looking for a `where` in `rust-rewind-to-beginning-of-current-level-expr`, check that it is not part of a string or comment. --- rust-mode-tests.el | 11 +++++++++++ 1 file changed, 11 insertions(+) (limited to 'rust-mode-tests.el') diff --git a/rust-mode-tests.el b/rust-mode-tests.el index de3900c..1e0207d 100644 --- a/rust-mode-tests.el +++ b/rust-mode-tests.el @@ -623,6 +623,17 @@ impl<'a, K, Q: ?Sized, V, S> Index<&'a Q> for HashMap } ")) +(ert-deftest indent-align-where-in-comment () + (test-indent + "/// - there must not exist an edge U->V in the graph where: +#[derive(Clone, PartialEq, Eq)] +pub struct Region { // <-- this should be flush with left margin! + entry: BasicBlockIndex, + leaves: BTreeMap, +} +")) + + (ert-deftest indent-square-bracket-alignment () (test-indent " -- cgit v1.2.3