summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorUlrich Müller <ulm@gentoo.org>2017-04-07 18:48:04 +0200
committerUlrich Müller <ulm@gentoo.org>2017-04-07 18:48:04 +0200
commit3451d7ab62b52cdf5c6d069c22ceceaf69c5b218 (patch)
treec44f69aff42ddaf4bd9acae2a60c8e0f286ec93d
parentUpdate the copyright line only once. (diff)
downloadebuild-mode-3451d7ab62b52cdf5c6d069c22ceceaf69c5b218.tar.gz
ebuild-mode-3451d7ab62b52cdf5c6d069c22ceceaf69c5b218.tar.bz2
ebuild-mode-3451d7ab62b52cdf5c6d069c22ceceaf69c5b218.zip
Call regexp-opt without duplicates in its argument list.
* ebuild-mode.el (ebuild-mode-make-keywords-list): Call regexp-opt without duplicates in its argument list.
-rw-r--r--ChangeLog5
-rw-r--r--ebuild-mode.el2
2 files changed, 6 insertions, 1 deletions
diff --git a/ChangeLog b/ChangeLog
index 5dc7fe2..4cd3357 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,8 @@
+2017-04-07 Ulrich Müller <ulm@gentoo.org>
+
+ * ebuild-mode.el (ebuild-mode-make-keywords-list): Call regexp-opt
+ without duplicates in its argument list.
+
2017-03-31 Ulrich Müller <ulm@gentoo.org>
* ebuild-mode.el (ebuild-mode-before-save):
diff --git a/ebuild-mode.el b/ebuild-mode.el
index d24355b..cdd06ef 100644
--- a/ebuild-mode.el
+++ b/ebuild-mode.el
@@ -213,7 +213,7 @@ of lines."
(error "Keywords argument must be a list of strings"))
(cons (concat prefix "\\<"
(let ((max-specpdl-size (max max-specpdl-size 2000)))
- (regexp-opt keywords-list t))
+ (regexp-opt (delete-dups keywords-list) t))
"\\>" suffix)
face))