From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!not-for-mail From: Stefan Monnier Newsgroups: gmane.emacs.bugs Subject: bug#5937: 23.1.95; why saving empty abbrev tables Date: Mon, 28 Mar 2011 23:31:13 -0400 Message-ID: References: NNTP-Posting-Host: lo.gmane.org Mime-Version: 1.0 Content-Type: text/plain X-Trace: dough.gmane.org 1301369843 23068 80.91.229.12 (29 Mar 2011 03:37:23 GMT) X-Complaints-To: usenet@dough.gmane.org NNTP-Posting-Date: Tue, 29 Mar 2011 03:37:23 +0000 (UTC) Cc: 5937@debbugs.gnu.org To: Leo Original-X-From: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane.org@gnu.org Tue Mar 29 05:37:18 2011 Return-path: Envelope-to: geb-bug-gnu-emacs@m.gmane.org Original-Received: from lists.gnu.org ([199.232.76.165]) by lo.gmane.org with esmtp (Exim 4.69) (envelope-from ) id 1Q4Pk6-00020M-60 for geb-bug-gnu-emacs@m.gmane.org; Tue, 29 Mar 2011 05:37:18 +0200 Original-Received: from localhost ([127.0.0.1]:35973 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1Q4Pk5-0001Wq-KU for geb-bug-gnu-emacs@m.gmane.org; Mon, 28 Mar 2011 23:37:17 -0400 Original-Received: from [140.186.70.92] (port=54032 helo=eggs.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1Q4Pjy-0001Wf-Ux for bug-gnu-emacs@gnu.org; Mon, 28 Mar 2011 23:37:11 -0400 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1Q4Pjx-00061V-RP for bug-gnu-emacs@gnu.org; Mon, 28 Mar 2011 23:37:10 -0400 Original-Received: from debbugs.gnu.org ([140.186.70.43]:50153) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1Q4Pjx-00061O-N0 for bug-gnu-emacs@gnu.org; Mon, 28 Mar 2011 23:37:09 -0400 Original-Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.69) (envelope-from ) id 1Q4Pf0-0001s7-7x; Mon, 28 Mar 2011 23:32:02 -0400 X-Loop: help-debbugs@gnu.org Resent-From: Stefan Monnier Original-Sender: debbugs-submit-bounces@debbugs.gnu.org Resent-To: owner@debbugs.gnu.org Resent-CC: bug-gnu-emacs@gnu.org Resent-Date: Tue, 29 Mar 2011 03:32:02 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 5937 X-GNU-PR-Package: emacs X-GNU-PR-Keywords: Original-Received: via spool by 5937-submit@debbugs.gnu.org id=B5937.13013694837145 (code B ref 5937); Tue, 29 Mar 2011 03:32:02 +0000 Original-Received: (at 5937) by debbugs.gnu.org; 29 Mar 2011 03:31:23 +0000 Original-Received: from localhost ([127.0.0.1] helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.69) (envelope-from ) id 1Q4PeM-0001rB-6G for submit@debbugs.gnu.org; Mon, 28 Mar 2011 23:31:22 -0400 Original-Received: from ironport2-out.teksavvy.com ([206.248.154.181] helo=ironport2-out.pppoe.ca) by debbugs.gnu.org with esmtp (Exim 4.69) (envelope-from ) id 1Q4PeK-0001qz-6j for 5937@debbugs.gnu.org; Mon, 28 Mar 2011 23:31:20 -0400 X-IronPort-Anti-Spam-Filtered: true X-IronPort-Anti-Spam-Result: AvsEADdRkU1MCqRC/2dsb2JhbAClSHiIdrwkhWoElgY X-IronPort-AV: E=Sophos;i="4.63,259,1299474000"; d="scan'208";a="98452033" Original-Received: from 76-10-164-66.dsl.teksavvy.com (HELO ceviche.home) ([76.10.164.66]) by ironport2-out.pppoe.ca with ESMTP/TLS/ADH-AES256-SHA; 28 Mar 2011 23:31:14 -0400 Original-Received: by ceviche.home (Postfix, from userid 20848) id BD5E6660C7; Mon, 28 Mar 2011 23:31:13 -0400 (EDT) In-Reply-To: (Leo's message of "Tue, 29 Mar 2011 08:35:22 +0800") User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/24.0.50 (gnu/linux) X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.11 Precedence: list Resent-Date: Mon, 28 Mar 2011 23:32:02 -0400 X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.6 (newer, 3) 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: , Original-Sender: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane.org@gnu.org Errors-To: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane.org@gnu.org Xref: news.gmane.org gmane.emacs.bugs:45455 Archived-At: >> I'd rather call edit-abbrevs-redefine from the new command you'll bind >> to C-x C-w. > Do you mean 'C-x C-s'? C-x C-w is bound to write-abbrev-file in the > patch? If so, I guess it makes sense not to bind C-x C-w. Oh, I didn't notice this part of the patch. So I guess what I'm suggesting is to create a new command for use in C-x C-w which calls edit-abbrevs-redefine and then calls interactively write-abbrev-file. The issue with write-abbrev-file is that it's called from save-some-buffers so we can't/shouldn't bind it to edit-abbrevs. Maybe another solution is to change edit-abbrevs-mode so that save-buffer and write-file work in it by calling internally write-abbrev-file. Note sure if that can be made to work without major surgery, tho (write-region-annotate-functions could do some of it, but I think the lack of buffer-file-name setting will get in the way, so we'd have to change edit-abbrevs so that it sets buffer-file-name and is really turned into a major mode to edit the .abbrev-defs file, which seems like a fairly different beast). Stefan