From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!not-for-mail From: Richard Stallman Newsgroups: gmane.emacs.devel Subject: Re: Removing unloaded functions from auto-mode-alist. Date: Wed, 20 Apr 2005 10:57:15 -0400 Message-ID: References: <87zmvu6ba2.fsf@xs4all.nl> <85ll7e68ei.fsf@lola.goethe.zz> <87wtqy4gvv.fsf@xs4all.nl> Reply-To: rms@gnu.org NNTP-Posting-Host: main.gmane.org X-Trace: sea.gmane.org 1114009321 12100 80.91.229.2 (20 Apr 2005 15:02:01 GMT) X-Complaints-To: usenet@sea.gmane.org NNTP-Posting-Date: Wed, 20 Apr 2005 15:02:01 +0000 (UTC) Cc: emacs-devel@gnu.org Original-X-From: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Wed Apr 20 17:02:00 2005 Return-path: Original-Received: from lists.gnu.org ([199.232.76.165]) by ciao.gmane.org with esmtp (Exim 4.43) id 1DOGhE-0003uR-SI for ged-emacs-devel@m.gmane.org; Wed, 20 Apr 2005 17:00:57 +0200 Original-Received: from localhost ([127.0.0.1] helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1DOGll-00037g-Ki for ged-emacs-devel@m.gmane.org; Wed, 20 Apr 2005 11:05:37 -0400 Original-Received: from mailman by lists.gnu.org with tmda-scanned (Exim 4.43) id 1DOGjg-0002Fm-6c for emacs-devel@gnu.org; Wed, 20 Apr 2005 11:03:28 -0400 Original-Received: from exim by lists.gnu.org with spam-scanned (Exim 4.43) id 1DOGjf-0002FG-8o for emacs-devel@gnu.org; Wed, 20 Apr 2005 11:03:27 -0400 Original-Received: from [199.232.76.173] (helo=monty-python.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1DOGje-0001Ln-T6 for emacs-devel@gnu.org; Wed, 20 Apr 2005 11:03:26 -0400 Original-Received: from [199.232.76.164] (helo=fencepost.gnu.org) by monty-python.gnu.org with esmtp (Exim 4.34) id 1DOGg6-0000qj-Bx for emacs-devel@gnu.org; Wed, 20 Apr 2005 10:59:46 -0400 Original-Received: from rms by fencepost.gnu.org with local (Exim 4.34) id 1DOGdf-0004Yi-O1; Wed, 20 Apr 2005 10:57:15 -0400 Original-To: Lute Kamstra In-reply-to: <87wtqy4gvv.fsf@xs4all.nl> (message from Lute Kamstra on Tue, 19 Apr 2005 23:05:08 +0200) 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:36168 X-Report-Spam: http://spam.gmane.org/gmane.emacs.devel:36168 I guess it can't hurt to leave a function on a hook or in auto-mode-alist if it is replaced by a restored autoload. (Even if feature x actually put it there.) See patch below. Erring on the other side seems more damaging: removing a function from a hook when that function was put there by a user's init file or something. Usually when a package defines a function and puts it on hooks, that function will not be autoloaded. If the function is autoloaded, that means it is meant to be used when the package is not loaded. So that function might be put on hooks by users before the package is loaded. So I think what you're proposing is the right criterion. It would be right most of the time.