From mboxrd@z Thu Jan 1 00:00:00 1970 Path: main.gmane.org!not-for-mail From: Ding Lei Newsgroups: gmane.emacs.help Subject: Infinite Multiline replacement problem Date: Sun, 27 Jun 2004 15:17:13 +0800 Sender: help-gnu-emacs-bounces+geh-help-gnu-emacs=m.gmane.org@gnu.org Message-ID: <87smchzczq.fsf@dinglei.ipanel.com.cn> NNTP-Posting-Host: deer.gmane.org Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii X-Trace: sea.gmane.org 1088320200 29021 80.91.224.253 (27 Jun 2004 07:10:00 GMT) X-Complaints-To: usenet@sea.gmane.org NNTP-Posting-Date: Sun, 27 Jun 2004 07:10:00 +0000 (UTC) Original-X-From: help-gnu-emacs-bounces+geh-help-gnu-emacs=m.gmane.org@gnu.org Sun Jun 27 09:09:53 2004 Return-path: Original-Received: from lists.gnu.org ([199.232.76.165]) by deer.gmane.org with esmtp (Exim 3.35 #1 (Debian)) id 1BeTnV-00070T-00 for ; Sun, 27 Jun 2004 09:09:53 +0200 Original-Received: from localhost ([127.0.0.1] helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.33) id 1BeTp3-0006Y2-9c for geh-help-gnu-emacs@m.gmane.org; Sun, 27 Jun 2004 03:11:29 -0400 Original-Received: from mailman by lists.gnu.org with tmda-scanned (Exim 4.33) id 1BeTov-0006VP-90 for help-gnu-emacs@gnu.org; Sun, 27 Jun 2004 03:11:21 -0400 Original-Received: from exim by lists.gnu.org with spam-scanned (Exim 4.33) id 1BeTos-0006Um-W1 for help-gnu-emacs@gnu.org; Sun, 27 Jun 2004 03:11:20 -0400 Original-Received: from [199.232.76.173] (helo=monty-python.gnu.org) by lists.gnu.org with esmtp (Exim 4.33) id 1BeTos-0006Uj-TT for help-gnu-emacs@gnu.org; Sun, 27 Jun 2004 03:11:18 -0400 Original-Received: from [221.4.106.43] (helo=ipanel.cn) by monty-python.gnu.org with esmtp (Exim 4.34) id 1BeTmr-00062u-EN for help-gnu-emacs@gnu.org; Sun, 27 Jun 2004 03:09:14 -0400 Original-Received: from dinglei.ipanel.com.cn (dinglei [127.0.0.1]) by ipanel.cn (Postfix) with ESMTP id 88900380BC for ; Sun, 27 Jun 2004 15:17:13 +0800 (CST) Original-To: help-gnu-emacs@gnu.org User-Agent: Gnus/5.110003 (No Gnus v0.3) Emacs/21.3.50 (gnu/linux) X-BeenThere: help-gnu-emacs@gnu.org X-Mailman-Version: 2.1.4 Precedence: list List-Id: Users list for the GNU Emacs text editor List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: help-gnu-emacs-bounces+geh-help-gnu-emacs=m.gmane.org@gnu.org Xref: main.gmane.org gmane.emacs.help:19044 X-Report-Spam: http://spam.gmane.org/gmane.emacs.help:19044 Hello list, I tried to use regexp replace to do a multiline replacement, but Emacs replaces one occurrence again and again (infinite) ... Here's the regexp I use, Replace: \*/[Ctrl-q][Ctrl-j]public void final With: *@ejb.persistence[Ctrl-q][Ctrl-j]*/[Ctrl-q][Ctrl-j]public void final As you could see, what I want to do is insert an additional "@ejb.persistence" string before the line "*/". But emacs always replaces the first occurrence, and the result is that numerous "*@ejb.persistence" string is inserted until *deadlock*. Thank you. -- Yours, <<<::::: D i n g L e i ::::::>> || || || Ext: 8106 || || Email: || || Dept. Of Technology/Engineering || || Embedded Internet Solutions Inc. || || || <(((((( ===================== )))))>>>