From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!not-for-mail From: Marcin Kasperski Newsgroups: gmane.emacs.bugs Subject: bug#15836: 24.3; query-replace-regexp does not detect incorrect usage of \# Date: Wed, 13 Nov 2013 21:34:58 +0100 Message-ID: References: <877gcjmbsh.fsf@softax.com.pl> <22a9hey6yj.fsf@fencepost.gnu.org> <55iow2iqcd.fsf@fencepost.gnu.org> NNTP-Posting-Host: plane.gmane.org Mime-Version: 1.0 Content-Type: text/plain; charset=ISO-8859-1 X-Trace: ger.gmane.org 1384375275 3296 80.91.229.3 (13 Nov 2013 20:41:15 GMT) X-Complaints-To: usenet@ger.gmane.org NNTP-Posting-Date: Wed, 13 Nov 2013 20:41:15 +0000 (UTC) Cc: 15836@debbugs.gnu.org, Marcin Kasperski To: Stefan Monnier Original-X-From: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane.org@gnu.org Wed Nov 13 21:41:19 2013 Return-path: Envelope-to: geb-bug-gnu-emacs@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 1VghFU-0006DT-Mf for geb-bug-gnu-emacs@m.gmane.org; Wed, 13 Nov 2013 21:41:16 +0100 Original-Received: from localhost ([::1]:50714 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1VghFU-0004Pw-9n for geb-bug-gnu-emacs@m.gmane.org; Wed, 13 Nov 2013 15:41:16 -0500 Original-Received: from eggs.gnu.org ([2001:4830:134:3::10]:55148) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1VghFL-0004P0-Qj for bug-gnu-emacs@gnu.org; Wed, 13 Nov 2013 15:41:12 -0500 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1VghFH-0006e3-1M for bug-gnu-emacs@gnu.org; Wed, 13 Nov 2013 15:41:07 -0500 Original-Received: from debbugs.gnu.org ([140.186.70.43]:36577) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1VghFG-0006dy-TQ for bug-gnu-emacs@gnu.org; Wed, 13 Nov 2013 15:41:02 -0500 Original-Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.80) (envelope-from ) id 1VghFG-0001UC-91 for bug-gnu-emacs@gnu.org; Wed, 13 Nov 2013 15:41:02 -0500 X-Loop: help-debbugs@gnu.org Resent-From: Marcin Kasperski Original-Sender: "Debbugs-submit" Resent-CC: bug-gnu-emacs@gnu.org Resent-Date: Wed, 13 Nov 2013 20:41:02 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 15836 X-GNU-PR-Package: emacs X-GNU-PR-Keywords: Original-Received: via spool by 15836-submit@debbugs.gnu.org id=B15836.13843752585700 (code B ref 15836); Wed, 13 Nov 2013 20:41:02 +0000 Original-Received: (at 15836) by debbugs.gnu.org; 13 Nov 2013 20:40:58 +0000 Original-Received: from localhost ([127.0.0.1]:50596 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.80) (envelope-from ) id 1VghFC-0001Tr-2p for submit@debbugs.gnu.org; Wed, 13 Nov 2013 15:40:58 -0500 Original-Received: from mail-ve0-f174.google.com ([209.85.128.174]:34457) by debbugs.gnu.org with esmtp (Exim 4.80) (envelope-from ) id 1Vgh9n-0001Eq-N0 for 15836@debbugs.gnu.org; Wed, 13 Nov 2013 15:35:24 -0500 Original-Received: by mail-ve0-f174.google.com with SMTP id cz12so749484veb.19 for <15836@debbugs.gnu.org>; Wed, 13 Nov 2013 12:35:18 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=mime-version:sender:in-reply-to:references:from:date:message-id :subject:to:cc:content-type; bh=jNi8qoJCdcWgbausa9vB3+C7xf00QQdQe8TVJeG0aBM=; b=z6LQQ3eBOTkb6nhra9EivaAjwo3mriTfj5mKntPSG9qI/YCMnNmHvTPbPbEB2FBiNS q5DOiWPFphM478Q3qy8DbatKPFYkW+pApHVXDkIZLbX8MGda9gNvElBH3x6g3PMVpt89 lGMlgG9f9itZONjWVKO626XDR2FjN1dJraOp9CYtrP2pxxerzyJL5yltv9EHWJs3L/wl Fn1xsl8ub88BG6N4G/nDj118HAKhaBPd3HZPbTC861u0Bg6QEj9hpdP5FYXct9So3N9z tI7g8sGgyQPLgmuiSgQ7RZVEmYLFAPQE9Zmru5NR0SW4Nw8d4iCBbSGV05WCz+SDV0q2 L2eg== X-Received: by 10.221.26.4 with SMTP id rk4mr156756vcb.70.1384374918092; Wed, 13 Nov 2013 12:35:18 -0800 (PST) Original-Received: by 10.58.19.229 with HTTP; Wed, 13 Nov 2013 12:34:58 -0800 (PST) In-Reply-To: X-Google-Sender-Auth: VrP58HfnwPit5BMz9D04OmyPCyE X-Mailman-Approved-At: Wed, 13 Nov 2013 15:40:56 -0500 X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.15 Precedence: list X-detected-operating-system: by eggs.gnu.org: GNU/Linux 3.x X-Received-From: 140.186.70.43 X-BeenThere: bug-gnu-emacs@gnu.org List-Id: "Bug reports for GNU Emacs, the Swiss army knife of text editors" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane.org@gnu.org Original-Sender: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane.org@gnu.org Xref: news.gmane.org gmane.emacs.bugs:80381 Archived-At: "Error evaluating replacement expression: ... " would be a bit better, it would point toward replacement expression as something suspicious. On Sat, Nov 9, 2013 at 12:15 AM, Stefan Monnier wrote: >> Hmm, perhaps replace-eval-replacement could temporarily bind >> the function definition of replace-count to some informative error >> message ("\# used in function context")? > > Sorry, I don't like this idea. Much too specific to the particular way > the user screwed up. > > I guess we could byte-compile the expression, which would give the user > actual warnings about his code before running it, but I'm afraid this > medicine would be worse than the disease. > > Another approach would be to refrain from substituting \# and > instead to let-bind it during the evaluation. > > > Stefan