[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[nongnu] elpa/evil-matchit 8fba4f12e1 208/244: minor issue in emacs lisp
From: |
ELPA Syncer |
Subject: |
[nongnu] elpa/evil-matchit 8fba4f12e1 208/244: minor issue in emacs lisp comment |
Date: |
Thu, 6 Jan 2022 02:59:02 -0500 (EST) |
branch: elpa/evil-matchit
commit 8fba4f12e1bbfdbf25a8ed2a5308840f104bc7c0
Author: Chen Bin <chenbin.sh@gmail.com>
Commit: Chen Bin <chenbin.sh@gmail.com>
minor issue in emacs lisp comment
---
evil-matchit-sdk.el | 6 +++---
evil-matchit.el | 4 ++--
pkg.sh | 2 +-
tests/evil-matchit-tests.el | 24 ++++++++++++++++++++++++
4 files changed, 30 insertions(+), 6 deletions(-)
diff --git a/evil-matchit-sdk.el b/evil-matchit-sdk.el
index 1ca71c2bdc..c3bde55711 100644
--- a/evil-matchit-sdk.el
+++ b/evil-matchit-sdk.el
@@ -103,11 +103,10 @@ If IS-FORWARD is t, jump forward; or else jump backward."
((evilmi-sdk-comment-p (point))
;; Matching tag in comment.
;; Use own algorithm instead of `scan-sexps'
- ;; because `scan-sexps' not work in some major-mode
+ ;; because `scan-sexps' does not work in some major modes
(save-excursion
(setq start-pos (point))
- (while (and (not (= start-pos limit))
- (> lvl 0))
+ (while (and e (not (= start-pos limit)) (> lvl 0))
(goto-char (setq start-pos (+ start-pos arg)))
(when (evilmi-sdk-comment-p start-pos)
(cond
@@ -117,6 +116,7 @@ If IS-FORWARD is t, jump forward; or else jump backward."
(setq lvl (1- lvl))))))
(when (= lvl 0)
(setq rlt (+ start-pos (if is-forward 1 0))))))
+
(t
;; not comment
;; search but ignore comments
diff --git a/evil-matchit.el b/evil-matchit.el
index 107a2b27ff..fbef487155 100644
--- a/evil-matchit.el
+++ b/evil-matchit.el
@@ -4,7 +4,7 @@
;; Author: Chen Bin <chenbin DOT sh AT gmail DOT com>
;; URL: http://github.com/redguardtoo/evil-matchit
-;; Version: 2.3.7
+;; Version: 2.3.8
;; Keywords: matchit vim evil
;; Package-Requires: ((evil "1.2.0") (emacs "24.4"))
;;
@@ -310,7 +310,7 @@ If IS-INNER is t, the region is inner text object."
(defun evilmi-version()
"Print version."
(interactive)
- (message "2.3.7"))
+ (message "2.3.8"))
(defvar evil-matchit-mode-map (make-sparse-keymap)
"Keymap used by the minor mode.")
diff --git a/pkg.sh b/pkg.sh
index 37a74b3bf4..8df15e6264 100755
--- a/pkg.sh
+++ b/pkg.sh
@@ -1,6 +1,6 @@
#!/bin/bash
name=evil-matchit
-version=2.3.7
+version=2.3.8
pkg=$name-$version
mkdir $pkg
cp README.org $pkg
diff --git a/tests/evil-matchit-tests.el b/tests/evil-matchit-tests.el
index feebc6cede..2a97c926e2 100644
--- a/tests/evil-matchit-tests.el
+++ b/tests/evil-matchit-tests.el
@@ -408,5 +408,29 @@
(should (eq major-mode 'markdown-mode))))
+(ert-deftest evilmi-test-emacs-lisp ()
+ (with-temp-buffer
+ (insert ";; test1\n"
+ ";; {{\n"
+ ";; java\n"
+ ";; }}\n"
+ "test\n")
+ (emacs-lisp-mode)
+ (font-lock-ensure)
+
+ (goto-char (point-min))
+ (forward-char 2)
+ (evilmi-jump-items)
+ ;; still at the same line if there is no bracket at point
+ (should (string= ";; test1" (evilmi-sdk-curline)))
+ ;; test matched brackets
+ (search-forward "{")
+ (evilmi-jump-items)
+ (should (string= ";; }}" (evilmi-sdk-curline)))
+ (evilmi-jump-items)
+ (should (string= ";; {{" (evilmi-sdk-curline)))
+
+ (should (eq major-mode 'emacs-lisp-mode))))
+
(ert-run-tests-batch-and-exit)
;;; evil-matchit-tests.el ends here
- [nongnu] elpa/evil-matchit dbaae2b753 127/244: Merge pull request #81 from neojski/ocaml, (continued)
- [nongnu] elpa/evil-matchit dbaae2b753 127/244: Merge pull request #81 from neojski/ocaml, ELPA Syncer, 2022/01/06
- [nongnu] elpa/evil-matchit dea3fca13b 168/244: clean code dependency, ELPA Syncer, 2022/01/06
- [nongnu] elpa/evil-matchit 64b572d2e4 166/244: Merge pull request #107 from porras/patch-2, ELPA Syncer, 2022/01/06
- [nongnu] elpa/evil-matchit 2a53963ffc 182/244: support php-mode, ELPA Syncer, 2022/01/06
- [nongnu] elpa/evil-matchit 076ace3ee2 188/244: README, ELPA Syncer, 2022/01/06
- [nongnu] elpa/evil-matchit ec0ea006e9 184/244: improve html tag matching algorithm, ELPA Syncer, 2022/01/06
- [nongnu] elpa/evil-matchit 943bf5fb2b 189/244: ruby code might use tab, ELPA Syncer, 2022/01/06
- [nongnu] elpa/evil-matchit b363d12390 202/244: fix evil-matchit-diff, ELPA Syncer, 2022/01/06
- [nongnu] elpa/evil-matchit 7cd10d332d 191/244: extra logic to find html open tag, ELPA Syncer, 2022/01/06
- [nongnu] elpa/evil-matchit 3076a8ca5d 232/244: org-mode can use simple rule, ELPA Syncer, 2022/01/06
- [nongnu] elpa/evil-matchit 8fba4f12e1 208/244: minor issue in emacs lisp comment,
ELPA Syncer <=
- [nongnu] elpa/evil-matchit f9faa0b9bf 244/244: README, ELPA Syncer, 2022/01/06
- [nongnu] elpa/evil-matchit 24a95751f4 239/244: Merge pull request #134 from dankessler/matlab-mode, ELPA Syncer, 2022/01/06
- [nongnu] elpa/evil-matchit 0f23f97aef 234/244: use github workflows instead of travis ci, ELPA Syncer, 2022/01/06
- [nongnu] elpa/evil-matchit b24a7232a2 218/244: support octave, requires emacs25+, clean up tests, ELPA Syncer, 2022/01/06
- [nongnu] elpa/evil-matchit c2d3798650 054/244: support template lik PHP, better algorithm v1.4.0, ELPA Syncer, 2022/01/06
- [nongnu] elpa/evil-matchit 67eec20d48 086/244: updated README, ELPA Syncer, 2022/01/06
- [nongnu] elpa/evil-matchit f981f722df 088/244: avoid hang in python-mode, v2.1.1, ELPA Syncer, 2022/01/06
- [nongnu] elpa/evil-matchit 0b35f26191 091/244: javascript could use evilmi-simple-*, ELPA Syncer, 2022/01/06
- [nongnu] elpa/evil-matchit 6346825fd8 099/244: less picky about latex tags, ELPA Syncer, 2022/01/06
- [nongnu] elpa/evil-matchit 080639aed3 100/244: clean code and doc, ELPA Syncer, 2022/01/06