summaryrefslogtreecommitdiff
path: root/lisp/international
diff options
context:
space:
mode:
authorPaul Eggert <eggert@cs.ucla.edu>2019-04-19 09:00:04 -0700
committerPaul Eggert <eggert@cs.ucla.edu>2019-04-19 09:02:25 -0700
commit9e4bb0d221bbd97f9318bacba0650d93708f0290 (patch)
tree0711cf59f86e4782cd8e0081921330097eb252de /lisp/international
parente6a9785f8228130c339aad5ba0a514fee6539cab (diff)
downloademacs-9e4bb0d221bbd97f9318bacba0650d93708f0290.tar.gz
Fix regexp branches that subsume other branches
Problems reported by Mattias Engdegård in: https://lists.gnu.org/r/emacs-devel/2019-04/msg00803.html * lisp/arc-mode.el (archive-rar-summarize): * lisp/eshell/em-hist.el (eshell-hist-word-designator): * lisp/info.el (Info-dir-remove-duplicates): * lisp/international/ja-dic-cnv.el (skkdic-convert-postfix) (skkdic-convert-prefix, skkdic-collect-okuri-nasi): * lisp/progmodes/cc-awk.el (c-awk-esc-pair-re): * lisp/xml.el (xml-att-type-re): Omit regexp branches that subsume other branches. * lisp/progmodes/cperl-mode.el (cperl-beautify-regexp-piece): $ and ^ aren’t simple-codes.
Diffstat (limited to 'lisp/international')
-rw-r--r--lisp/international/ja-dic-cnv.el10
1 files changed, 5 insertions, 5 deletions
diff --git a/lisp/international/ja-dic-cnv.el b/lisp/international/ja-dic-cnv.el
index 578cd63a590..e7210831891 100644
--- a/lisp/international/ja-dic-cnv.el
+++ b/lisp/international/ja-dic-cnv.el
@@ -124,7 +124,7 @@
(setq l (cdr l)))))
;; Search postfix entries.
- (while (re-search-forward "^[#<>?]\\(\\(\\cH\\|ー\\)+\\) " nil t)
+ (while (re-search-forward "^[#<>?]\\(\\cH+\\) " nil t)
(let ((kana (match-string-no-properties 1))
str candidates)
(while (looking-at "/[#0-9 ]*\\([^/\n]*\\)/")
@@ -157,7 +157,7 @@
(insert ";; Setting prefix entries.\n"
"(skkdic-set-prefix\n"))
(save-excursion
- (while (re-search-forward "^\\(\\(\\cH\\|ー\\)+\\)[<>?] " nil t)
+ (while (re-search-forward "^\\(\\cH+\\)[<>?] " nil t)
(let ((kana (match-string-no-properties 1))
str candidates)
(while (looking-at "/\\([^/\n]+\\)/")
@@ -275,11 +275,11 @@
(let ((progress (make-progress-reporter "Collecting OKURI-NASI entries"
(point) (point-max)
nil 10)))
- (while (re-search-forward "^\\(\\(\\cH\\|ー\\)+\\) \\(/\\cj.*\\)/$"
+ (while (re-search-forward "^\\(\\cH+\\) \\(/\\cj.*\\)/$"
nil t)
(let ((kana (match-string-no-properties 1))
- (candidates (skkdic-get-candidate-list (match-beginning 3)
- (match-end 3))))
+ (candidates (skkdic-get-candidate-list (match-beginning 2)
+ (match-end 2))))
(setq skkdic-okuri-nasi-entries
(cons (cons kana candidates) skkdic-okuri-nasi-entries))
(progress-reporter-update progress (point))