From mboxrd@z Thu Jan 1 00:00:00 1970 Path: main.gmane.org!not-for-mail From: Ami Fischman Newsgroups: gmane.emacs.bugs Subject: Re: please implement query-exchange Date: Tue, 19 Nov 2002 09:25:19 -0800 Sender: bug-gnu-emacs-admin@gnu.org Message-ID: References: <87isyynuk3.fsf@jidanni.org> <1438-Sat16Nov2002211425+0200-eliz@is.elta.co.il> NNTP-Posting-Host: main.gmane.org Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii X-Trace: main.gmane.org 1037726833 31898 80.91.224.249 (19 Nov 2002 17:27:13 GMT) X-Complaints-To: usenet@main.gmane.org NNTP-Posting-Date: Tue, 19 Nov 2002 17:27:13 +0000 (UTC) Return-path: Original-Received: from monty-python.gnu.org ([199.232.76.173]) by main.gmane.org with esmtp (Exim 3.35 #1 (Debian)) id 18EC9W-0008Hv-00 for ; Tue, 19 Nov 2002 18:27:10 +0100 Original-Received: from localhost ([127.0.0.1] helo=monty-python.gnu.org) by monty-python.gnu.org with esmtp (Exim 4.10) id 18EC9f-0003B7-00; Tue, 19 Nov 2002 12:27:19 -0500 Original-Received: from list by monty-python.gnu.org with tmda-scanned (Exim 4.10) id 18EC8m-0002DA-00 for bug-gnu-emacs@gnu.org; Tue, 19 Nov 2002 12:26:24 -0500 Original-Received: from mail by monty-python.gnu.org with spam-scanned (Exim 4.10) id 18EC8i-00024h-00 for bug-gnu-emacs@gnu.org; Tue, 19 Nov 2002 12:26:23 -0500 Original-Received: from main.gmane.org ([80.91.224.249]) by monty-python.gnu.org with esmtp (Exim 4.10) id 18EC8h-000229-00 for bug-gnu-emacs@gnu.org; Tue, 19 Nov 2002 12:26:19 -0500 Original-Received: from list by main.gmane.org with local (Exim 3.35 #1 (Debian)) id 18EC6P-00084H-00 for ; Tue, 19 Nov 2002 18:23:57 +0100 Original-To: bug-gnu-emacs@gnu.org X-Injected-Via-Gmane: http://gmane.org/ Original-Received: from news by main.gmane.org with local (Exim 3.35 #1 (Debian)) id 18EC5t-00081m-00 for ; Tue, 19 Nov 2002 18:23:25 +0100 Original-Path: not-for-mail Original-Lines: 22 Original-NNTP-Posting-Host: 12-228-169-213.client.attbi.com Original-X-Trace: main.gmane.org 1037726605 30817 12.228.169.213 (19 Nov 2002 17:23:25 GMT) Original-X-Complaints-To: usenet@main.gmane.org Original-NNTP-Posting-Date: Tue, 19 Nov 2002 17:23:25 +0000 (UTC) Mail-Copies-To: nobody User-Agent: Gnus/5.090008 (Oort Gnus v0.08) Emacs/21.2.50 (i686-pc-linux-gnu) Cancel-Lock: sha1:m+AHXsLJOPW868w7mnHsxukVM8w= Errors-To: bug-gnu-emacs-admin@gnu.org X-BeenThere: bug-gnu-emacs@gnu.org X-Mailman-Version: 2.0.11 Precedence: bulk List-Help: List-Post: List-Subscribe: , List-Id: Bug reports for GNU Emacs, the Swiss army knife of text editors List-Unsubscribe: , List-Archive: Xref: main.gmane.org gmane.emacs.bugs:3910 X-Report-Spam: http://spam.gmane.org/gmane.emacs.bugs:3910 "Eli Zaretskii" writes: [...] > Can't you do that with query-replace-regexp using parenthesized > subexpressions and the \N feature (where N is a digit)? Is this really possible? When I first read your post, I just said to myself "oh, yeah, that's right; that should take care of it" but later on I actually tried to implement a query-exchange function using only one query-replace-regexp, and couldn't figure out how to do it. I see from (a private email?) that Dan posted to the list that you suggested to him a regexp that would take care of his particular string of text, but I'm now more curious about the general problem. Can anyone here implement an exchange in a single RE replace? More an academic challenge than an emacs bug (or even feature request) since what Dan was asking for can be done in a lisp function anyway. Cheers, -- Ami Fischman usenet@fischman.org