From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!not-for-mail From: Juri Linkov Newsgroups: gmane.emacs.devel Subject: Re: isearch-allow-move [Was: isearch-allow-prefix] Date: Tue, 11 Jun 2013 22:35:53 +0300 Organization: JURTA Message-ID: <874nd4e98u.fsf@mail.jurta.org> References: <20130525200103.GA3451@acm.acm> <878v32aj3c.fsf@mail.jurta.org> <20130602210512.GC2765@acm.acm> <87sj0xn484.fsf@mail.jurta.org> <20130604212400.GB2492@acm.acm> <87d2s1otjb.fsf@mail.jurta.org> <20130605210241.GA3730@acm.acm> <8761xr93h5.fsf_-_@mail.jurta.org> <20130606200719.GA3911@acm.acm> <87ehcexw3u.fsf@mail.jurta.org> <20130607103057.GA3199@acm.acm> <87hah9lnw5.fsf@mail.jurta.org> <87fvwrnj0r.fsf@mail.jurta.org> NNTP-Posting-Host: plane.gmane.org Mime-Version: 1.0 Content-Type: text/plain X-Trace: ger.gmane.org 1370979605 26108 80.91.229.3 (11 Jun 2013 19:40:05 GMT) X-Complaints-To: usenet@ger.gmane.org NNTP-Posting-Date: Tue, 11 Jun 2013 19:40:05 +0000 (UTC) Cc: Alan Mackenzie , Stefan Monnier , Drew Adams To: emacs-devel@gnu.org Original-X-From: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Tue Jun 11 21:40:04 2013 Return-path: Envelope-to: ged-emacs-devel@m.gmane.org Original-Received: from lists.gnu.org ([208.118.235.17]) by plane.gmane.org with esmtp (Exim 4.69) (envelope-from ) id 1UmUQG-0002ia-HQ for ged-emacs-devel@m.gmane.org; Tue, 11 Jun 2013 21:40:04 +0200 Original-Received: from localhost ([::1]:33086 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1UmUQF-0003oM-Qy for ged-emacs-devel@m.gmane.org; Tue, 11 Jun 2013 15:40:03 -0400 Original-Received: from eggs.gnu.org ([2001:4830:134:3::10]:57417) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1UmUQC-0003nM-AZ for emacs-devel@gnu.org; Tue, 11 Jun 2013 15:40:01 -0400 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1UmUQB-000687-Gr for emacs-devel@gnu.org; Tue, 11 Jun 2013 15:40:00 -0400 Original-Received: from ps18281.dreamhost.com ([69.163.218.105]:53337 helo=ps18281.dreamhostps.com) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1UmUQB-00067u-CJ for emacs-devel@gnu.org; Tue, 11 Jun 2013 15:39:59 -0400 Original-Received: from localhost (ps18281.dreamhostps.com [69.163.218.105]) by ps18281.dreamhostps.com (Postfix) with ESMTP id C65A5258B9E938; Tue, 11 Jun 2013 12:39:56 -0700 (PDT) In-Reply-To: <87fvwrnj0r.fsf@mail.jurta.org> (Juri Linkov's message of "Sun, 09 Jun 2013 23:09:24 +0300") User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/24.3.50 (x86_64-pc-linux-gnu) X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.2.x-3.x (no timestamps) [generic] X-Received-From: 69.163.218.105 X-BeenThere: emacs-devel@gnu.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: "Emacs development discussions." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Original-Sender: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Xref: news.gmane.org gmane.emacs.devel:160351 Archived-At: > `isearch-symbol-regexp' requires the same changes > that will make it a copy of `word-search-regexp' > that uses "\\_<" and "\\_>" instead of "\\b". But it also requires changing "\\W+" (used in `word-search-regexp') to a regexp that doesn't match symbols. IOW, in a word search `word-search-regexp' uses the "\\W+" regexp to skip non-word characters, so `isearch-symbol-regexp' needs to do the same to also skip non-symbol characters. Unfortunately I have no idea how to do this. What is needed is a negation of the regexp "\\(\\sw\\|\\s_\\)+" to match any character except the ones that have word syntax or symbol syntax. Naively I tried "[^\\sw\\s_]+" but it fails to work the same way as it works for e.g. "[^[:word:]]". Whereas (skip-syntax-forward "^w_") moves point across characters whose syntax is not word or symbol, I see no way to do the same with a regexp. Could someone please help me write a regexp that matches a non-word non-symbol character?