|
From: | Andreas Röhler |
Subject: | bug#33375: 27.0.50; Nested function definitions |
Date: | Wed, 14 Nov 2018 12:46:40 +0100 |
User-agent: | Mozilla/5.0 (X11; Linux i686; rv:52.0) Gecko/20100101 Thunderbird/52.9.1 |
On 14.11.2018 11:06, Andreas Röhler wrote:
On 14.11.2018 10:39, Andreas Röhler wrote:In GNU Emacs 27.0.50 (build 2, i686-pc-linux-gnu, GTK+ Version 3.14.5) of 2018-11-09
Some test which should display the issue: (ert-deftest ar-backward-defun-test-1977mjB () (with-temp-buffer (insert "(defun foo1 () \"[Some docu] \(defun other-foo \" (interactive) \;\; defining another function inside (defun foo2 () (interactive) (message \"%s\" \"Foo2\") \;\; another syntactically correct function just badly indented \(defun foo3 () (interactive) (message \"%s\" \"Foo3\")) ) (message \"%s\" \"Foo1\"))") (emacs-lisp-mode) (switch-to-buffer (current-buffer)) (goto-char (point-max)) (back-to-indentation) (if (functionp 'ar-backward-defun) (ar-backward-defun) (beginning-of-defun)) (should (looking-at "(defun foo1")))) (ert-deftest ar-backward-defun-test-1977ztH () (with-temp-buffer (insert "(defun foo1 () \"[Some docu] \(defun other-foo \" (interactive) \;\; defining another function inside (defun foo2 () (interactive) (message \"%s\" \"Foo2\") \;\; another syntactically correct function just badly indented \(defun foo3 () (interactive) (message \"%s\" \"Foo3\")) ) (message \"%s\" \"Foo1\"))") (emacs-lisp-mode) (switch-to-buffer (current-buffer)) (goto-char (point-max)) (search-backward "foo2") (if (functionp 'ar-backward-defun) (ar-backward-defun) (beginning-of-defun)) (should (looking-at " +(defun foo2")))) (ert-deftest ar-backward-defun-test-1977A4N () (with-temp-buffer (insert "(defun foo1 () \"[Some docu] \(defun other-foo \" (interactive) \;\; defining another function inside (defun foo2 () (interactive) (message \"%s\" \"Foo2\") \;\; another syntactically correct function just badly indented \(defun foo3 () (interactive) (message \"%s\" \"Foo3\")) ) (message \"%s\" \"Foo1\"))") (emacs-lisp-mode) (switch-to-buffer (current-buffer)) (goto-char (point-max)) (search-backward "Foo3") (forward-line 1) (if (functionp 'ar-backward-defun) (ar-backward-defun) (beginning-of-defun)) (should (looking-at "(defun foo2"))))
[Prev in Thread] | Current Thread | [Next in Thread] |