From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!not-for-mail From: Cameron Desautels Newsgroups: gmane.emacs.bugs Subject: bug#19328: [PATCH] Add mechanism to prompt about unsaved customizations Date: Tue, 9 Dec 2014 10:16:44 -0600 Message-ID: <8DD29730-77B2-49C6-9FB4-8ABF0D73C2E4@gmail.com> References: <745fafd0-6bc9-40f7-830f-32a916dd898e@default> NNTP-Posting-Host: plane.gmane.org Mime-Version: 1.0 (Mac OS X Mail 8.1 \(1993\)) Content-Type: text/plain; charset=us-ascii Content-Transfer-Encoding: 7bit X-Trace: ger.gmane.org 1418141896 24689 80.91.229.3 (9 Dec 2014 16:18:16 GMT) X-Complaints-To: usenet@ger.gmane.org NNTP-Posting-Date: Tue, 9 Dec 2014 16:18:16 +0000 (UTC) Cc: 19328@debbugs.gnu.org To: Drew Adams Original-X-From: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane.org@gnu.org Tue Dec 09 17:18:10 2014 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 1XyNUD-0007DI-NK for geb-bug-gnu-emacs@m.gmane.org; Tue, 09 Dec 2014 17:18:05 +0100 Original-Received: from localhost ([::1]:41219 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1XyNUD-0006a6-7j for geb-bug-gnu-emacs@m.gmane.org; Tue, 09 Dec 2014 11:18:05 -0500 Original-Received: from eggs.gnu.org ([2001:4830:134:3::10]:50509) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1XyNTL-0005PR-Ik for bug-gnu-emacs@gnu.org; Tue, 09 Dec 2014 11:17:17 -0500 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1XyNTC-0002rS-PA for bug-gnu-emacs@gnu.org; Tue, 09 Dec 2014 11:17:11 -0500 Original-Received: from debbugs.gnu.org ([140.186.70.43]:34407) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1XyNTC-0002rO-In for bug-gnu-emacs@gnu.org; Tue, 09 Dec 2014 11:17:02 -0500 Original-Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.80) (envelope-from ) id 1XyNTC-0006Rw-Cw for bug-gnu-emacs@gnu.org; Tue, 09 Dec 2014 11:17:02 -0500 X-Loop: help-debbugs@gnu.org Resent-From: Cameron Desautels Original-Sender: "Debbugs-submit" Resent-CC: bug-gnu-emacs@gnu.org Resent-Date: Tue, 09 Dec 2014 16:17:02 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 19328 X-GNU-PR-Package: emacs X-GNU-PR-Keywords: patch Original-Received: via spool by 19328-submit@debbugs.gnu.org id=B19328.141814180924745 (code B ref 19328); Tue, 09 Dec 2014 16:17:02 +0000 Original-Received: (at 19328) by debbugs.gnu.org; 9 Dec 2014 16:16:49 +0000 Original-Received: from localhost ([127.0.0.1]:59849 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.80) (envelope-from ) id 1XyNSy-0006R2-NV for submit@debbugs.gnu.org; Tue, 09 Dec 2014 11:16:49 -0500 Original-Received: from mail-oi0-f53.google.com ([209.85.218.53]:61680) by debbugs.gnu.org with esmtp (Exim 4.80) (envelope-from ) id 1XyNSw-0006Qs-OD for 19328@debbugs.gnu.org; Tue, 09 Dec 2014 11:16:47 -0500 Original-Received: by mail-oi0-f53.google.com with SMTP id x69so607915oia.40 for <19328@debbugs.gnu.org>; Tue, 09 Dec 2014 08:16:46 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=subject:mime-version:content-type:from:in-reply-to:date:cc :content-transfer-encoding:message-id:references:to; bh=O9FAf9HJqqG5nXZjC5MMX5v4lS7ACrvfAHGGzgAhlzY=; b=vkdHv4bCV/QQOfFRvCXsjFlkuI78iQqZa2+EJBRSkJyIkcf368Do+e5DeuRxojZDI7 XWNIKGjfMa2hThm5KIl4gtZ1UFnT7pzrvAu42GnJlNkq1m4JBbbQfw3ovpsERZBF51Bb UKY7LajtQKgIGFm1JtBdppNoON/bzEOlC4JyxFRiFTonnNmQjWKt5Q1mnPXVlVsOKrZz ukOPFtUZGOIsRAiZO/qw1nv0NKfpxJmUFOeMs9M50SUG+09TV5o7DEOZLTSHeL6acrzy 11LOCg084Tvo0Kj6c67b3PbPliUGkswgiUiPvUz+ThgWfDMao/f38AnsNKvVviktjKpL 20zQ== X-Received: by 10.202.17.142 with SMTP id 136mr9576978oir.51.1418141806297; Tue, 09 Dec 2014 08:16:46 -0800 (PST) Original-Received: from [192.168.168.59] (rrcs-24-227-130-234.sw.biz.rr.com. [24.227.130.234]) by mx.google.com with ESMTPSA id e8sm645272oev.4.2014.12.09.08.16.45 for (version=TLSv1 cipher=ECDHE-RSA-RC4-SHA bits=128/128); Tue, 09 Dec 2014 08:16:45 -0800 (PST) X-Priority: 3 In-Reply-To: <745fafd0-6bc9-40f7-830f-32a916dd898e@default> X-Mailer: Apple Mail (2.1993) 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:97086 Archived-At: > On 2014-12-09, at 9:54 AM, Drew Adams wrote: > > Why is this in etc/TODO? If you're asking me in particular, I don't know. I just found it there and thought I'd help out. > This already exists, no? I've been using this for years: > > (add-hook 'kill-emacs-query-functions > (lambda () > (condition-case nil > (customize-unsaved) > (error t)))) A named function is probably more suitable for an end user than an arbitrary lambda, no? Plus using error handling for control flow is generally not considered a best practice, especially when it's as broad in scope as `(condition-case nil ...)`. -- Cameron Desautels