Subject: Re: bug#10885: Replace expressions: enhance functionality when searching in filled paragraphs

From: Dani Moncayo <[email-masked]>
Date: Tue, 28 Feb 2012 11:04:55 +0100

> Would it make sense for replace-regexp/query-replace-regexp (and other
> commands
> that read regexps from the user) to respect search-whitespace-regexp, just
> like
> isearch?

Good question.

Quote from the docstring of `isearch-forward-regexp':

 In regexp incremental searches, a space or spaces normally matches
 any whitespace (the variable `search-whitespace-regexp' controls
 precisely what that means).  If you want to search for a literal space
 and nothing else, enter C-q SPC.

Does anyone knows why `query-replace-regexp' don't behave that way too?

I think it should, i.e., `query-replace-regexp' should find the same
matches that `isearch-forward-regexp' would find with the same search
regexp.

-- 
Dani Moncayo