From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.io!.POSTED.blaine.gmane.org!not-for-mail From: Richard Stallman Newsgroups: gmane.emacs.devel Subject: Re: Lisp files that load cl-lib in problematical ways Date: Sun, 22 Oct 2023 22:08:55 -0400 Message-ID: References: <87il8betof.fsf@dataswamp.org> <83fs3dgxv8.fsf@gnu.org> <835y38qvlg.fsf@gnu.org> <87bkcx6eci.fsf@dataswamp.org> <83ttqnm4ti.fsf@gnu.org> Reply-To: rms@gnu.org Content-Type: text/plain; charset=Utf-8 Injection-Info: ciao.gmane.io; posting-host="blaine.gmane.org:116.202.254.214"; logging-data="8042"; mail-complaints-to="usenet@ciao.gmane.io" Cc: emacs-devel@gnu.org To: Alan Mackenzie Original-X-From: emacs-devel-bounces+ged-emacs-devel=m.gmane-mx.org@gnu.org Mon Oct 23 04:09:38 2023 Return-path: Envelope-to: ged-emacs-devel@m.gmane-mx.org Original-Received: from lists.gnu.org ([209.51.188.17]) by ciao.gmane.io with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.92) (envelope-from ) id 1qukNt-0001uu-Un for ged-emacs-devel@m.gmane-mx.org; Mon, 23 Oct 2023 04:09:38 +0200 Original-Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1qukNF-0003aS-Ot; Sun, 22 Oct 2023 22:08:57 -0400 Original-Received: from eggs.gnu.org ([2001:470:142:3::10]) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1qukNE-0003aC-RO for emacs-devel@gnu.org; Sun, 22 Oct 2023 22:08:56 -0400 Original-Received: from fencepost.gnu.org ([2001:470:142:3::e]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1qukNE-0007OB-2E; Sun, 22 Oct 2023 22:08:56 -0400 DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=gnu.org; s=fencepost-gnu-org; h=Date:References:Subject:In-Reply-To:To:From: mime-version; bh=5SY9DaS7v/YKGJFdFpazY/BtBOArtCKPXzu9aU4bAsg=; b=i9tFVv2nCWLk m3Wi9LeJaUCv1F0MIry86KA536SsqSPL/jRbI1Mcq8pP4tfEFF62FcYbEQjdR0ZnhGsVRCbsEDa8O jj6vtHQ2Jud0T14+6HtngQ9P/wRSHSiswy20b/sDQCDgzqBiePxQS+ECDdzwZfHIwD7f/01Y6tLbv 4rHQBEtJbkJIr5O5cz3S5UTXCJa6Shd3AKoQvd5rfM03/MSrioeYv5sfIm8wJhAvXNmuKjxxyGb6X 9CAdv4w1hBTtjKHobJBUm7gYGPo6Qt20E86fnslGEjSrx621vG914iXFYQxf26hibGcu0x1/2+okO UCvFNkOU1m4NGw3dqsKtYw==; Original-Received: from rms by fencepost.gnu.org with local (Exim 4.90_1) (envelope-from ) id 1qukND-0006Hr-R2; Sun, 22 Oct 2023 22:08:55 -0400 In-Reply-To: (message from Alan Mackenzie on Thu, 19 Oct 2023 12:34:42 +0000) X-BeenThere: emacs-devel@gnu.org X-Mailman-Version: 2.1.29 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-mx.org@gnu.org Original-Sender: emacs-devel-bounces+ged-emacs-devel=m.gmane-mx.org@gnu.org Xref: news.gmane.io gmane.emacs.devel:311689 Archived-At: [[[ To any NSA and FBI agents reading my email: please consider ]]] [[[ whether defending the US Constitution against all enemies, ]]] [[[ foreign or domestic, requires you to follow Snowden's example. ]]] > and got the following results: > abbrev.el:2 A generally useful minor mode as abbrev.el should not load cl-lib. Why does it? I investigated. abbrev--check-chars uses the macro cl-pushnew. Generally we arrange for cl- macros not to load cl-lib. But cl-pushnew is _defined_ in cl-lib. It ought to be defined with and like other cl- macros that are meant for users to use. That's a bug, and probably not a deep one. Would someone please fix it? I investigated byte-run.el. I don't think it uses any cl- facility. Rather, it declares a let-variable whose name starts with cl-. I think that if we investigate the other general-purpose packages in the list you posted (I copied it below), we wlll find many such bugs that got in because developers were not on guard against them. Once we fix them all, how about if we add a regression test to verify that various packages anyone might load at any time do not use cl-lib. With that, bugs like this would get caught right away. Here's the list, with some files crossed off that I've just handled. ;; abbrev.el:2 dnd.el:4 ;; emacs-lisp/byte-run.el:1 emacs-lisp/cconv.el:13 emacs-lisp/cl-generic.el:56 emacs-lisp/cl-preloaded.el:16 emacs-lisp/eldoc.el:6 emacs-lisp/lisp-mode.el:6 emacs-lisp/nadvice.el:2 emacs-lisp/oclosure.el:8 emacs-lisp/seq.el:25 emacs-lisp/shorthands.el:1 emacs-lisp/syntax.el:5 emacs-lisp/tabulated-list.el:1 emacs-lisp/timer.el:1 font-lock.el:1 frame.el:5 international/mule-cmds.el:3 international/ucs-normalize.el:1 isearch.el:3 ldefs-boot.el:3 loaddefs.el:3 minibuffer.el:12 progmodes/elisp-mode.el:11 progmodes/prog-mode.el:1 register.el:3 replace.el:1 select.el:3 simple.el:9 startup.el:1 subr.el:1 tab-bar.el:4 term/android-win.el:4 term/haiku-win.el:3 term/ns-win.el:2 term/pc-win.el:6 term/pgtk-win.el:3 term/w32-win.el:4 term/x-win.el:2 uniquify.el:2 vc/vc-hooks.el:1 -- Dr Richard Stallman (https://stallman.org) Chief GNUisance of the GNU Project (https://gnu.org) Founder, Free Software Foundation (https://fsf.org) Internet Hall-of-Famer (https://internethalloffame.org)