GNU bug report logs - #22494
still can't search for two spaces

Previous Next

Package: emacs;

Reported by: 積丹尼 Dan Jacobson <jidanni <at> jidanni.org>

Date: Sat, 30 Jan 2016 06:35:02 UTC

Severity: minor

Tags: notabug

Done: Glenn Morris <rgm <at> gnu.org>

Bug is archived. No further changes may be made.

Full log


View this message in rfc822 format

From: Dani Moncayo <dmoncayo <at> gmail.com>
To: Andreas Schwab <schwab <at> suse.de>
Cc: 22494 <at> debbugs.gnu.org, mbork <at> mbork.pl, Richard Stallman <rms <at> gnu.org>, Dan Jacobson <jidanni <at> jidanni.org>
Subject: bug#22494: still can't search for two spaces
Date: Mon, 1 Feb 2016 15:15:55 +0100
>>   > What is in the search string is a search pattern.  How it is
>>   > interpreted is the question.
>>
>> Right.  And I am proposing a way to interpret part of it.  Namely,
>> two spaces in a row means to match two spaces in the buffer.
>
> But if you isearch-yank them they should be normalized so that they
> continue to do lax matching.

Quoting from [1]:

  IMO, Emacs should refrain from making permanent changes to the search
  string, as given by the user.  IOW, the search string should be kept
  untouched, and any transformations of it should be done "on the fly"
  to achieve the intended behavior, based on both the _current_ search
  string and the _current_ user options that govern the search behavior.

  That way, if/when either the search string or the user options
  changes, Emacs will be able to exhibit the expected behavior.

IOW, I don't think that normalization is a good idea.

But I agree with you that two (or more) consecutive spaces should
be treated specially _only_ if they were *typed* by the user (not
yanked from the kill ring or grabbed from the buffer)

---
Dani Moncayo

[1] http://debbugs.gnu.org/cgi/bugreport.cgi?bug=16546#43




This bug report was last modified 9 years and 167 days ago.

Previous Next


GNU bug tracking system
Copyright (C) 1999 Darren O. Benham, 1997,2003 nCipher Corporation Ltd, 1994-97 Ian Jackson.