From: Richard M. Stallman Date: Thu, 25 Oct 2001 15:26:46 +0000 (+0000) Subject: (tags-query-replace): Make tags-loop-scan X-Git-Tag: ttn-vms-21-2-B4~19158 X-Git-Url: http://git.eshelyaron.com/gitweb/?a=commitdiff_plain;h=c2c3a05deb42b36fd50ec196acd0d505a10b39cf;p=emacs.git (tags-query-replace): Make tags-loop-scan bind case-fold-search if FROM is not all lower case. --- diff --git a/lisp/progmodes/etags.el b/lisp/progmodes/etags.el index 6f46e3103a8..d1e357aee5d 100644 --- a/lisp/progmodes/etags.el +++ b/lisp/progmodes/etags.el @@ -1737,12 +1737,15 @@ with the command \\[tags-loop-continue]. See documentation of variable `tags-file-name'." (interactive (query-replace-read-args "Tags query replace (regexp)" t)) (setq tags-loop-scan (list 'prog1 - (list 'if (list 're-search-forward - (list 'quote from) nil t) - ;; When we find a match, move back - ;; to the beginning of it so perform-replace - ;; will see it. - '(goto-char (match-beginning 0)))) + (list 'let + (if (not (equal from (downcase from))) + '((case-fold-search nil))) + (list 'if (list 're-search-forward + (list 'quote from) nil t) + ;; When we find a match, move back + ;; to the beginning of it so + ;; perform-replace will see it. + '(goto-char (match-beginning 0))))) tags-loop-operate (list 'perform-replace (list 'quote from) (list 'quote to) t t (list 'quote delimited)))