From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!not-for-mail From: Stefan Monnier Newsgroups: gmane.emacs.devel Subject: Re: [elpa] master 9173a44 1/2: [Fix #12] Don't autodisable beacon on hl-line-mode Date: Sun, 18 Oct 2015 20:56:07 -0400 Message-ID: References: <20151017213254.5317.59042@vcs.savannah.gnu.org> NNTP-Posting-Host: plane.gmane.org Mime-Version: 1.0 Content-Type: text/plain X-Trace: ger.gmane.org 1445216187 14873 80.91.229.3 (19 Oct 2015 00:56:27 GMT) X-Complaints-To: usenet@ger.gmane.org NNTP-Posting-Date: Mon, 19 Oct 2015 00:56:27 +0000 (UTC) Cc: emacs-devel To: Artur Malabarba Original-X-From: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Mon Oct 19 02:56:18 2015 Return-path: Envelope-to: ged-emacs-devel@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 1ZnykL-0006Ai-8p for ged-emacs-devel@m.gmane.org; Mon, 19 Oct 2015 02:56:17 +0200 Original-Received: from localhost ([::1]:36056 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1ZnykK-0006Ij-5d for ged-emacs-devel@m.gmane.org; Sun, 18 Oct 2015 20:56:16 -0400 Original-Received: from eggs.gnu.org ([2001:4830:134:3::10]:33907) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1ZnykH-0006Ie-9L for emacs-devel@gnu.org; Sun, 18 Oct 2015 20:56:14 -0400 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1ZnykD-0000n8-4o for emacs-devel@gnu.org; Sun, 18 Oct 2015 20:56:13 -0400 Original-Received: from ironport2-out.teksavvy.com ([206.248.154.181]:26720) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1ZnykD-0000n4-0U for emacs-devel@gnu.org; Sun, 18 Oct 2015 20:56:09 -0400 X-IronPort-Anti-Spam-Filtered: true X-IronPort-Anti-Spam-Result: A0AsEwA731xV/1/x92hcgxCEAoVVuzcJh0sEAgKBPDkUAQEBAQEBAYEKQQWDXQEBAwFWIwULCw4mEhQYDSSINwjPIwEBAQEGAQEBAR6LOoUFB4QtBbUEI4I7gVkigngBAQE X-IPAS-Result: A0AsEwA731xV/1/x92hcgxCEAoVVuzcJh0sEAgKBPDkUAQEBAQEBAYEKQQWDXQEBAwFWIwULCw4mEhQYDSSINwjPIwEBAQEGAQEBAR6LOoUFB4QtBbUEI4I7gVkigngBAQE X-IronPort-AV: E=Sophos;i="5.13,465,1427774400"; d="scan'208";a="170128747" Original-Received: from 104-247-241-95.cpe.teksavvy.com (HELO pastel.home) ([104.247.241.95]) by ironport2-out.teksavvy.com with ESMTP; 18 Oct 2015 20:56:08 -0400 Original-Received: by pastel.home (Postfix, from userid 20848) id 78B6E628FA; Sun, 18 Oct 2015 20:56:07 -0400 (EDT) In-Reply-To: (Artur Malabarba's message of "Sun, 18 Oct 2015 19:48:05 +0100") User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/25.0.50 (gnu/linux) X-detected-operating-system: by eggs.gnu.org: Genre and OS details not recognized. X-Received-From: 206.248.154.181 X-BeenThere: emacs-devel@gnu.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: "Emacs development discussions." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Original-Sender: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Xref: news.gmane.org gmane.emacs.devel:192023 Archived-At: > Then I'm clearly unaware of something here. > There was a discussion here a few months ago where I learned that > hooks should always be defined with nil initial values. > So, if it must be defined empty, and it's wrong to add entries to it > later, then what's the correct way for a package to have a non-empty > hook? A custom var shouldn't be modified programmatically. But hook should usually be modified via `add-hook' (i.e. programmatically). Ergo, hooks are better defined with defvar than with defcustom. Otherwise, define 2 hooks: a defvar one, modified via add-hook, and a defcustom one, only modified via Custom. Stefan