]> git.eshelyaron.com Git - emacs.git/commitdiff
* lisp/progmodes/f90.el (f90-no-block-limit):
authorGlenn Morris <rgm@gnu.org>
Mon, 2 Nov 2015 02:25:42 +0000 (18:25 -0800)
committerGlenn Morris <rgm@gnu.org>
Mon, 2 Nov 2015 02:25:42 +0000 (18:25 -0800)
Add associate.  (Bug#21794)
* test/automated/f90.el (f90-test-bug21794): New test.

lisp/progmodes/f90.el
test/automated/f90.el

index 5c938fd1a93d94eead69226de77a9f4945309bda..0e333f1f7ed54b487f694b22ea4215c0419f1caa 100644 (file)
@@ -1452,7 +1452,7 @@ if all else fails."
     (not (or (looking-at "end")
              (looking-at "\\(do\\|if\\|else\\(if\\|where\\)?\
 \\|select[ \t]*\\(case\\|type\\)\\|case\\|where\\|forall\\|\
-block\\|critical\\|enum\\)\\_>")
+block\\|critical\\|enum\\|associate\\)\\_>")
              (looking-at "\\(program\\|\\(?:sub\\)?module\\|\
 \\(?:abstract[ \t]*\\)?interface\\|block[ \t]*data\\)\\_>")
              (looking-at "\\(contains\\|\\(?:\\sw\\|\\s_\\)+[ \t]*:\\)")
index c521d289a5dbf95d4dde2e0d85c0398c15ff5f75..e429b21c09203a7c6080e4e75b42d08cc3044fd1 100644 (file)
@@ -240,4 +240,19 @@ end module modname")
     (forward-line -1)
     (should (= 2 (current-indentation)))))
 
+(ert-deftest f90-test-bug21794 ()
+  "Test for http://debbugs.gnu.org/21794 ."
+  (with-temp-buffer
+    (f90-mode)
+    (insert "program prog
+do i=1,10
+associate (x => xa(i), y => ya(i))
+a(x,y,i) = fun(x,y,i)
+end associate
+end do
+end program prog")
+    (f90-indent-subprogram)
+    (forward-line -2)
+    (should (= 5 (current-indentation)))))
+
 ;;; f90.el ends here