bug-gnu-emacs
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

bug#10705: 24.0.93; Collect strings matching regexp from Isearch


From: Juri Linkov
Subject: bug#10705: 24.0.93; Collect strings matching regexp from Isearch
Date: Sat, 04 Feb 2012 02:14:15 +0200
User-agent: Gnus/5.13 (Gnus v5.13) Emacs/24.0.93 (x86_64-pc-linux-gnu)

>>  Interactively, REGEXP is the current search regexp or a quoted search
>>  string.  NLINES has the same meaning as in `occur'."
>
> is not clear enough: what is a "quoted search string"?  I'd suggest to
> describe explicitly the 3 cases handled by the code:
>
>> +      (regexp (cond
>> +               (isearch-word (word-search-regexp isearch-string))
>> +               (isearch-regexp isearch-string)
>> +               (t (regexp-quote isearch-string)))))
>
> and refer to the relevant string in each case.

Is this better?

=== modified file 'lisp/isearch.el'
--- lisp/isearch.el     2012-02-03 23:50:41 +0000
+++ lisp/isearch.el     2012-02-04 00:10:01 +0000
@@ -1464,8 +1464,11 @@ (defun isearch-query-replace-regexp (&op
 
 (defun isearch-occur (regexp &optional nlines)
   "Run `occur' with regexp to search from the current search string.
-Interactively, REGEXP is the current search regexp or a quoted search
-string.  NLINES has the same meaning as in `occur'."
+Interactively, in word search REGEXP is computed from words
+without regard to punctuation, in regexp search REGEXP is
+the current search regexp, in normal search REGEXP is created
+from the current search string quoting all special regexp characters.
+NLINES has the same meaning as in `occur'."
   (interactive
    (let* ((perform-collect (consp current-prefix-arg))
          (regexp (cond


BTW, shouldn't this new feature (collecting strings with `C-u M-x occur')
be announced in NEWS?





reply via email to

[Prev in Thread] Current Thread [Next in Thread]