From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.io!.POSTED.blaine.gmane.org!not-for-mail From: Eli Zaretskii Newsgroups: gmane.emacs.devel Subject: Re: What's missing in ELisp that makes people want to use cl-lib? Date: Sat, 28 Oct 2023 22:14:22 +0300 Message-ID: <8334xud0fl.fsf@gnu.org> References: <83ttqnm4ti.fsf@gnu.org> <831qdlpoye.fsf@gnu.org> <83sf5xhnym.fsf@gnu.org> <871qdhk49w.fsf@dataswamp.org> <25914.49745.111873.734458@orion.rgrjr.com> Injection-Info: ciao.gmane.io; posting-host="blaine.gmane.org:116.202.254.214"; logging-data="26634"; mail-complaints-to="usenet@ciao.gmane.io" Cc: stefankangas@gmail.com, rms@gnu.org, rogers@rgrjr.com, emacs-devel@gnu.org To: Jim Porter Original-X-From: emacs-devel-bounces+ged-emacs-devel=m.gmane-mx.org@gnu.org Sat Oct 28 21:15:12 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 1qwom8-0006iO-65 for ged-emacs-devel@m.gmane-mx.org; Sat, 28 Oct 2023 21:15:12 +0200 Original-Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1qwolq-0000Ko-Th; Sat, 28 Oct 2023 15:14:55 -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 1qwolo-0000Kf-QM for emacs-devel@gnu.org; Sat, 28 Oct 2023 15:14:52 -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 1qwolo-0007PS-Eo; Sat, 28 Oct 2023 15:14:52 -0400 DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=gnu.org; s=fencepost-gnu-org; h=References:Subject:In-Reply-To:To:From:Date: mime-version; bh=Yz3Ln3gxSubKjGBiijey0kwoMjXSl3Sv+VfaA7uAbEg=; b=pcbMKQgj+a/G XvZhHC6BG8SuVsTCh7awoa57P9776pHJP3g5VUfQm9AAeA4dZM0KOJoWhjERhtpg0/bxrX1GFv92w jd/9Uq/jJxFHQdBbywyIqTg001bbL1i0uUY3jXWiLbc9HO4vnM4yWzw7L6F52ZhafOuE2sJ1AJiqc xoEnDZF7m2/mtOxOA4V4ztgFL6xENyaTn8hIRoUfpJQacenSJkUnx9n7d+rp5RemkeBBUxluzqQsg y7rzdyjssQrQXb0licj6njJQ14OfMv6Yxj8b5w1eo0RhqSNGI+IvfQELzwApBMW3rcaq+JxGaM7Wl NHqJKeIQr+VGIsYKSKhLew==; In-Reply-To: (message from Jim Porter on Sat, 28 Oct 2023 12:10:23 -0700) 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:311963 Archived-At: > Date: Sat, 28 Oct 2023 12:10:23 -0700 > Cc: emacs-devel@gnu.org > From: Jim Porter > > On 10/28/2023 8:39 AM, Stefan Kangas wrote: > > Is it possible that certain abstractions or functions are filling a gap > > in Emacs Lisp itself? In the case of `cl-pushnew', I happen to think > > that the answer is yes. > > I agree with this. I can speak about Eshell in particular, since it's > historically used a bit of cl-lib, and I've added more usage to it. > > By far the number one cl-lib thing Eshell uses is 'cl-assert'. cl-assert is a macro in cl-macs, so it isn't relevant to this discussion. > After that, the next most important cl-lib thing (in my opinion) is > generic functions. If you mean cl-defgeneric and cl-defmethod, they again are not in cl-lib, so not relevant to this discussion. Moreover, they are defined in cl-generic.el, which is preloaded. > Related to the above is 'cl-defstruct'. cl-defstruct is again a macro in cl-macs, not in cl-lib. > Finally, Eshell uses a few miscellaneous cl-lib functions, some of which > are probably necessary, and some of which are just conveniences. The > (probable) necessities are: cl-progv and cl-mapc. The conveniences are: > cl-loop, cl-flet, cl-list*, cl-remove-if, cl-incf, and cl-decf. These are the only ones relevant to this discussion.