mirror of
git://git.sv.gnu.org/emacs.git
synced 2026-02-17 01:34:21 +00:00
gnus-util.el (gnus-string-match-p): New function, that is an alias to string-match-p in Emacs >=23.
gnus-msg.el (gnus-configure-posting-styles) nnir.el (nnir-run-gmane): Use gnus-string-match-p.
This commit is contained in:
parent
42d9cffad2
commit
87732ef36a
4 changed files with 18 additions and 2 deletions
|
|
@ -1,3 +1,11 @@
|
|||
2010-11-01 Katsumi Yamaoka <yamaoka@jpl.org>
|
||||
|
||||
* gnus-util.el (gnus-string-match-p): New function, that is an alias to
|
||||
string-match-p in Emacs >=23.
|
||||
|
||||
* gnus-msg.el (gnus-configure-posting-styles)
|
||||
* nnir.el (nnir-run-gmane): Use gnus-string-match-p.
|
||||
|
||||
2010-11-01 Glenn Morris <rgm@gnu.org>
|
||||
|
||||
* nnir.el (declare-function): Add compat stub.
|
||||
|
|
|
|||
|
|
@ -1892,7 +1892,7 @@ this is a reply."
|
|||
(cond
|
||||
((stringp value)
|
||||
(if (and (stringp match)
|
||||
(string-match-p "\\\\[&[:digit:]]" value)
|
||||
(gnus-string-match-p "\\\\[&[:digit:]]" value)
|
||||
(match-beginning 1))
|
||||
(gnus-match-substitute-replacement value nil nil group)
|
||||
value))
|
||||
|
|
|
|||
|
|
@ -2010,6 +2010,14 @@ This is the definition of match-substitute-replacement in subr.el from GNU Emacs
|
|||
(match-data t)))
|
||||
(replace-match replacement fixedcase literal match subexp)))))))
|
||||
|
||||
(if (fboundp 'string-match-p)
|
||||
(defalias 'gnus-string-match-p 'string-match-p)
|
||||
(defsubst gnus-string-match-p (regexp string &optional start)
|
||||
"\
|
||||
Same as `string-match' except this function does not change the match data."
|
||||
(save-match-data
|
||||
(string-match regexp string start))))
|
||||
|
||||
(provide 'gnus-util)
|
||||
|
||||
;;; gnus-util.el ends here
|
||||
|
|
|
|||
|
|
@ -1392,7 +1392,7 @@ Tested with Namazu 2.0.6 on a GNU/Linux system."
|
|||
;; gmane interface
|
||||
(defun nnir-run-gmane (query srv &optional groups)
|
||||
"Run a search against a gmane back-end server."
|
||||
(if (string-match-p "gmane" srv)
|
||||
(if (gnus-string-match-p "gmane" srv)
|
||||
(let* ((case-fold-search t)
|
||||
(qstring (cdr (assq 'query query)))
|
||||
(server (cadr (gnus-server-to-method srv)))
|
||||
|
|
|
|||
Loading…
Reference in a new issue