emacs-elpa-diffs
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[nongnu] elpa/rust-mode e6e16cc 102/486: Add test for closing braces in


From: ELPA Syncer
Subject: [nongnu] elpa/rust-mode e6e16cc 102/486: Add test for closing braces in character literals
Date: Sat, 7 Aug 2021 09:24:58 -0400 (EDT)

branch: elpa/rust-mode
commit e6e16ccc21a64f4b333273f58a7bd6d0376f70f4
Author: Micah Chalmer <micah@micahchalmer.net>
Commit: Micah Chalmer <micah@micahchalmer.net>

    Add test for closing braces in character literals
---
 rust-mode-tests.el | 12 ++++++++++++
 1 file changed, 12 insertions(+)

diff --git a/rust-mode-tests.el b/rust-mode-tests.el
index f4512f4..2b18728 100644
--- a/rust-mode-tests.el
+++ b/rust-mode-tests.el
@@ -526,6 +526,18 @@ fn foo() {
 "
    ))
 
+;; Closing braces in single char literals and strings should not confuse the 
indentation
+(ert-deftest indent-closing-braces-in-char-literals ()
+  (test-indent
+   "
+fn foo() {
+    { bar('}'); }
+    { bar(']'); }
+    { bar(')'); }
+}
+"
+   ))
+
 (setq rust-test-motion-string
       "
 fn fn1(arg: int) -> bool {



reply via email to

[Prev in Thread] Current Thread [Next in Thread]