From: Richard M. Stallman Date: Sun, 4 May 1997 01:20:08 +0000 (+0000) Subject: (occur): If regexp has uppercase in it, match it case-sensitively. X-Git-Tag: emacs-20.1~2307 X-Git-Url: http://git.eshelyaron.com/gitweb/?a=commitdiff_plain;h=9483d601ec99cd2c786d593005653dfab196d7de;p=emacs.git (occur): If regexp has uppercase in it, match it case-sensitively. --- diff --git a/lisp/replace.el b/lisp/replace.el index 24411f4739f..30109b87ba7 100644 --- a/lisp/replace.el +++ b/lisp/replace.el @@ -348,7 +348,10 @@ Interactively it is the prefix arg. The lines are shown in a buffer named `*Occur*'. It serves as a menu to find any of the occurrences in this buffer. -\\[describe-mode] in that buffer will explain how." +\\[describe-mode] in that buffer will explain how. + +If REGEXP contains upper case characters (excluding those preceded by +\\), the matching is case-sensitive." (interactive (list (let* ((default (car regexp-history)) (input @@ -371,6 +374,8 @@ It serves as a menu to find any of the occurrences in this buffer. (dir default-directory) (linenum 1) (prevpos (point-min)) + (case-fold-search (and case-fold-search + (isearch-no-upper-case-p regexp t))) (final-context-start (make-marker))) ;;; (save-excursion ;;; (beginning-of-line)