From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!not-for-mail From: Stefan Monnier Newsgroups: gmane.emacs.devel,gmane.emacs.pretest.bugs Subject: Re: 23.0.60; M-x occur no longer uses previous regexp as default Date: Tue, 22 Apr 2008 21:47:14 -0400 Message-ID: References: <87fxtexhta.fsf@gmx.de> <87abjlcwq7.fsf@jurta.org> NNTP-Posting-Host: lo.gmane.org Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii X-Trace: ger.gmane.org 1208916132 13823 80.91.229.12 (23 Apr 2008 02:02:12 GMT) X-Complaints-To: usenet@ger.gmane.org NNTP-Posting-Date: Wed, 23 Apr 2008 02:02:12 +0000 (UTC) Cc: emacs-pretest-bug@gnu.org, rfrancoise@debian.org, rms@gnu.org, Sven Joachim To: Juri Linkov Original-X-From: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Wed Apr 23 04:02:44 2008 connect(): Connection refused Return-path: Envelope-to: ged-emacs-devel@m.gmane.org Original-Received: from lists.gnu.org ([199.232.76.165]) by lo.gmane.org with esmtp (Exim 4.50) id 1JoUJn-0005Cn-Kf for ged-emacs-devel@m.gmane.org; Wed, 23 Apr 2008 04:02:43 +0200 Original-Received: from localhost ([127.0.0.1] helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1JoUJ8-0002mW-1S for ged-emacs-devel@m.gmane.org; Tue, 22 Apr 2008 22:02:02 -0400 Original-Received: from mailman by lists.gnu.org with tmda-scanned (Exim 4.43) id 1JoUJ3-0002ka-JW for emacs-devel@gnu.org; Tue, 22 Apr 2008 22:01:57 -0400 Original-Received: from exim by lists.gnu.org with spam-scanned (Exim 4.43) id 1JoUJ1-0002iE-AY for emacs-devel@gnu.org; Tue, 22 Apr 2008 22:01:55 -0400 Original-Received: from [199.232.76.173] (helo=monty-python.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1JoUJ0-0002hH-Gm for emacs-devel@gnu.org; Tue, 22 Apr 2008 22:01:54 -0400 Original-Received: from fencepost.gnu.org ([140.186.70.10]) by monty-python.gnu.org with esmtp (Exim 4.60) (envelope-from ) id 1JoUIz-0006VU-RQ for emacs-devel@gnu.org; Tue, 22 Apr 2008 22:01:53 -0400 Original-Received: from mx10.gnu.org ([199.232.76.166]) by fencepost.gnu.org with esmtp (Exim 4.67) (envelope-from ) id 1JoUIy-00052t-RO for emacs-pretest-bug@gnu.org; Tue, 22 Apr 2008 22:01:53 -0400 Original-Received: from Debian-exim by monty-python.gnu.org with spam-scanned (Exim 4.60) (envelope-from ) id 1JoU52-0004D3-Uz for emacs-pretest-bug@gnu.org; Tue, 22 Apr 2008 21:47:32 -0400 Original-Received: from ironport2-out.pppoe.ca ([206.248.154.182] helo=ironport2-out.teksavvy.com) by monty-python.gnu.org with esmtp (Exim 4.60) (envelope-from ) id 1JoU52-0004Cx-OB; Tue, 22 Apr 2008 21:47:28 -0400 X-IronPort-Anti-Spam-Filtered: true X-IronPort-Anti-Spam-Result: Ah4CAKcyDkjO+KGddGdsb2JhbACBUpACASqbLA X-IronPort-AV: E=Sophos;i="4.25,696,1199682000"; d="scan'208";a="18899944" Original-Received: from smtp.pppoe.ca (HELO smtp.teksavvy.com) ([65.39.196.238]) by ironport2-out.teksavvy.com with ESMTP; 22 Apr 2008 21:47:15 -0400 Original-Received: from pastel.home ([206.248.161.157]) by smtp.teksavvy.com (Internet Mail Server v1.0) with ESMTP id DFS20615; Tue, 22 Apr 2008 21:47:15 -0400 Original-Received: by pastel.home (Postfix, from userid 20848) id E0F218066; Tue, 22 Apr 2008 21:47:14 -0400 (EDT) In-Reply-To: <87abjlcwq7.fsf@jurta.org> (Juri Linkov's message of "Wed, 23 Apr 2008 02:14:18 +0300") User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/23.0.60 (gnu/linux) X-detected-kernel: by monty-python.gnu.org: Genre and OS details not recognized. X-detected-kernel: by monty-python.gnu.org: Linux 2.6, seldom 2.4 (older, 4) X-BeenThere: emacs-devel@gnu.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: "Emacs development discussions." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Original-Sender: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Errors-To: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Xref: news.gmane.org gmane.emacs.devel:95820 gmane.emacs.pretest.bugs:22114 Archived-At: > The reason for removing the previous regexp from default was because > it makes more inconvenient to retrieve more available values from > the list of default values via M-n. But maybe we could just display > the previous regexp in the prompt and accept it when the user types RET > with the empty string, but don't make it available via M-n, because it is > available via M-p for inserting into the minibuffer for editing. Then why not use (let ((ret (read-string (format "Regexp (default %s): " foo)))) (if (equal ret "") foo ret)) > Alternatively, we could change the occur engine to display all lines for > the "" regexp. This is not useful, but at least can be expected for "". Signalling an error in the function's code is better. Making sure the interactive spec never returns "" is also better (and not mutually exclusive). Stefan