[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[nongnu] elpa/evil-nerd-commenter ace8a7efd3 1/2: clean code
From: |
ELPA Syncer |
Subject: |
[nongnu] elpa/evil-nerd-commenter ace8a7efd3 1/2: clean code |
Date: |
Wed, 7 Dec 2022 07:58:49 -0500 (EST) |
branch: elpa/evil-nerd-commenter
commit ace8a7efd3975ad9f749b249df770c6b97e160ce
Author: Chen Bin <chenbin.sh@gmail.com>
Commit: Chen Bin <chenbin.sh@gmail.com>
clean code
---
evil-nerd-commenter.el | 7 +++----
1 file changed, 3 insertions(+), 4 deletions(-)
diff --git a/evil-nerd-commenter.el b/evil-nerd-commenter.el
index 258a6e3398..ef29009e1d 100644
--- a/evil-nerd-commenter.el
+++ b/evil-nerd-commenter.el
@@ -263,10 +263,9 @@ See
http://lists.gnu.org/archive/html/bug-gnu-emacs/2013-03/msg00891.html."
;; (or (match-end 1) (match-beginning 0)))
;; (do-something))
;; My regex makes sure (match-end 1) return the position of comment starter
- (if (and (boundp 'comment-use-syntax) (not comment-use-syntax))
- ;; Maybe autoconf.el will (setq comment-use-syntax t) in the future?
- (setq comment-start-skip "^\\(\\s*\\)\\(dnl\\|#\\) +"))
- )
+ (when (and (boundp 'comment-use-syntax) (not comment-use-syntax))
+ ;; Maybe autoconf.el will (setq comment-use-syntax t) in the future?
+ (setq comment-start-skip "^\\(\\s*\\)\\(dnl\\|#\\) +")))
((eq major-mode 'haml-mode)
(setq comment-use-syntax nil)
(setq comment-start "-# ")