From mboxrd@z Thu Jan 1 00:00:00 1970 Path: main.gmane.org!not-for-mail From: Stefan Monnier Newsgroups: gmane.emacs.devel Subject: Re: improving query-replace and query-replace-regexp Date: 01 Jun 2004 20:10:59 -0400 Sender: emacs-devel-bounces+emacs-devel=quimby.gnus.org@gnu.org Message-ID: References: <20040528.182035.197345599.wl@gnu.org> <87k6yvorzf.fsf@mail.jurta.org> <20040529213132.GA31322@fencepost> <873c5hd35q.fsf@mail.jurta.org> <20040602000401.GA20242@fencepost> NNTP-Posting-Host: deer.gmane.org Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii X-Trace: sea.gmane.org 1086135192 31314 80.91.224.253 (2 Jun 2004 00:13:12 GMT) X-Complaints-To: usenet@sea.gmane.org NNTP-Posting-Date: Wed, 2 Jun 2004 00:13:12 +0000 (UTC) Cc: Juri Linkov , wl@gnu.org, rms@gnu.org, emacs-devel@gnu.org Original-X-From: emacs-devel-bounces+emacs-devel=quimby.gnus.org@gnu.org Wed Jun 02 02:13:01 2004 Return-path: Original-Received: from quimby.gnus.org ([80.91.224.244]) by deer.gmane.org with esmtp (Exim 3.35 #1 (Debian)) id 1BVJNN-00057p-00 for ; Wed, 02 Jun 2004 02:13:01 +0200 Original-Received: from lists.gnu.org ([199.232.76.165]) by quimby.gnus.org with esmtp (Exim 3.35 #1 (Debian)) id 1BVJNM-0000CC-00 for ; Wed, 02 Jun 2004 02:13:01 +0200 Original-Received: from localhost ([127.0.0.1] helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.33) id 1BVJNc-0005mz-UW for emacs-devel@quimby.gnus.org; Tue, 01 Jun 2004 20:13:16 -0400 Original-Received: from mailman by lists.gnu.org with tmda-scanned (Exim 4.33) id 1BVJNa-0005mq-2a for emacs-devel@gnu.org; Tue, 01 Jun 2004 20:13:14 -0400 Original-Received: from exim by lists.gnu.org with spam-scanned (Exim 4.33) id 1BVJNW-0005mT-1c for emacs-devel@gnu.org; Tue, 01 Jun 2004 20:13:13 -0400 Original-Received: from [199.232.76.173] (helo=monty-python.gnu.org) by lists.gnu.org with esmtp (Exim 4.33) id 1BVJNV-0005mH-V0 for emacs-devel@gnu.org; Tue, 01 Jun 2004 20:13:09 -0400 Original-Received: from [132.204.24.67] (helo=mercure.iro.umontreal.ca) by monty-python.gnu.org with esmtp (Exim 4.34) id 1BVJLe-0006Nd-4e; Tue, 01 Jun 2004 20:11:14 -0400 Original-Received: from asado.iro.umontreal.ca (asado.iro.umontreal.ca [132.204.24.84]) by mercure.iro.umontreal.ca (Postfix) with ESMTP id D0AC3B302F1; Tue, 1 Jun 2004 20:11:00 -0400 (EDT) Original-Received: by asado.iro.umontreal.ca (Postfix, from userid 20848) id 1C0D28CA23; Tue, 1 Jun 2004 20:11:00 -0400 (EDT) Original-To: Miles Bader In-Reply-To: <20040602000401.GA20242@fencepost> Original-Lines: 38 User-Agent: Gnus/5.09 (Gnus v5.9.0) Emacs/21.3.50 X-DIRO-MailScanner-Information: Please contact the ISP for more information X-DIRO-MailScanner: Found to be clean X-DIRO-MailScanner-SpamCheck: n'est pas un polluriel, SpamAssassin (score=0, requis 5) X-MailScanner-From: monnier@iro.umontreal.ca X-BeenThere: emacs-devel@gnu.org X-Mailman-Version: 2.1.4 Precedence: list List-Id: "Emacs development discussions." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: emacs-devel-bounces+emacs-devel=quimby.gnus.org@gnu.org Xref: main.gmane.org gmane.emacs.devel:24375 X-Report-Spam: http://spam.gmane.org/gmane.emacs.devel:24375 > The standard emacs syntax for prompt defaults seems to be "(default ...)"; is > there any reason to use some different syntax here? [I know, things are not > exactly consistent as it is, but let's not make it worse.] I've seen both (default foo) and [foo] used and I personally prefer the second form because it is shorter. BTW, here is a suggested patch to deal with this second form in minibuffer-eldef. Stefan --- orig/lisp/minibuf-eldef.el +++ mod/lisp/minibuf-eldef.el @@ -1,6 +1,6 @@ ;;; minibuf-eldef.el --- Only show defaults in prompts when applicable ;; -;; Copyright (C) 2000, 2001 Free Software Foundation, Inc. +;; Copyright (C) 2000, 01, 2004 Free Software Foundation, Inc. ;; ;; Author: Miles Bader ;; Keywords: convenience @@ -36,7 +36,7 @@ ;;; Code: (defvar minibuffer-default-in-prompt-regexps - '(("\\( (default\\>.*)\\):? \\'" . 1)) + '(("\\( (default\\>.*)\\):? \\'" . 1) ("\\( \\[.*\\]\\): \\'" . 1)) "*A list of regexps matching the parts of minibuffer prompts showing defaults. When `minibuffer-electric-default-mode' is active, these regexps are used to identify the portions of prompts to elide. @@ -157,5 +157,5 @@ (provide 'minibuf-eldef) -;;; arch-tag: 7e421fae-c275-4729-b0da-7836af377d3d +;; arch-tag: 7e421fae-c275-4729-b0da-7836af377d3d ;;; minibuf-eldef.el ends here