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.bugs Subject: bug#75310: Eliminate obsolete alias warning Date: Sat, 04 Jan 2025 10:29:08 +0200 Message-ID: <86a5c7f0dn.fsf@gnu.org> References: <86h66ggl6a.fsf@gnu.org> <02134785-ad5d-8b9a-4b51-64e8d466b038@mavit.org.uk> <86bjwogewx.fsf@gnu.org> <868qrrhq8h.fsf@gnu.org> <77CBB14F-094D-48DA-A7D1-ED9E1F43DAD3@gmail.com> Mime-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit Injection-Info: ciao.gmane.io; posting-host="blaine.gmane.org:116.202.254.214"; logging-data="4987"; mail-complaints-to="usenet@ciao.gmane.io" Cc: p.d.oliver@mavit.org.uk, 75310@debbugs.gnu.org To: Yuan Fu Original-X-From: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane-mx.org@gnu.org Sat Jan 04 09:30:21 2025 Return-path: Envelope-to: geb-bug-gnu-emacs@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 1tTzY5-00018T-KP for geb-bug-gnu-emacs@m.gmane-mx.org; Sat, 04 Jan 2025 09:30:21 +0100 Original-Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1tTzXr-0008Kh-Ns; Sat, 04 Jan 2025 03:30:07 -0500 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 1tTzXm-0008HS-SC for bug-gnu-emacs@gnu.org; Sat, 04 Jan 2025 03:30:06 -0500 Original-Received: from debbugs.gnu.org ([2001:470:142:5::43]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1tTzXm-0005Vg-JN for bug-gnu-emacs@gnu.org; Sat, 04 Jan 2025 03:30:02 -0500 DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=debbugs.gnu.org; s=debbugs-gnu-org; h=MIME-version:References:In-Reply-To:From:Date:To:Subject; bh=VxK5cb08N0u7+D8yApbZsNojmR/sp5o/9+P8Adkx60c=; b=P0HW6DViyxVZJ6pBLcQI+CgdmPjzE5nZKtFNKnQ75zcFTitwmHI7am9NzfH7YvjUw/KVgn7wKMyPROqxmGTWf2eSQ8O9uwhO93zU9iWiA9r2zXUaezwB1G7TSNBCZsAE44YaJ2SKayZUQp8+PyJyNi04i4ASdo5EjYT+AZGegAo+8nAiqjVsqD371NMtELZFXOFtfE1XsfHoMjfdKJ4LJdDkmLXkZRZMDUuWWwLW4oUl5VV4SwTodn3q2KW/sVVOQPWnbiv5bddW8L8XH2fgKg29Zym9LmbHST+bq2X6JBHta2PEqCoyTDnPxEBsnR/jmK+Xy8POl3lPLLk+eI5AmQ==; Original-Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1tTzXm-0002Zu-D8 for bug-gnu-emacs@gnu.org; Sat, 04 Jan 2025 03:30:02 -0500 X-Loop: help-debbugs@gnu.org Resent-From: Eli Zaretskii Original-Sender: "Debbugs-submit" Resent-CC: bug-gnu-emacs@gnu.org Resent-Date: Sat, 04 Jan 2025 08:30:02 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 75310 X-GNU-PR-Package: emacs Original-Received: via spool by 75310-submit@debbugs.gnu.org id=B75310.17359793579800 (code B ref 75310); Sat, 04 Jan 2025 08:30:02 +0000 Original-Received: (at 75310) by debbugs.gnu.org; 4 Jan 2025 08:29:17 +0000 Original-Received: from localhost ([127.0.0.1]:53302 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1tTzX3-0002Y0-2G for submit@debbugs.gnu.org; Sat, 04 Jan 2025 03:29:17 -0500 Original-Received: from eggs.gnu.org ([2001:470:142:3::10]:39722) by debbugs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.84_2) (envelope-from ) id 1tTzX1-0002Xm-7r for 75310@debbugs.gnu.org; Sat, 04 Jan 2025 03:29:15 -0500 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 1tTzWv-0005Q6-Mq; Sat, 04 Jan 2025 03:29:09 -0500 DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=gnu.org; s=fencepost-gnu-org; h=MIME-version:References:Subject:In-Reply-To:To:From: Date; bh=VxK5cb08N0u7+D8yApbZsNojmR/sp5o/9+P8Adkx60c=; b=oY7okozsg+5An9/LKYzB Iaun35Goik/Z7oPFhFHzP5yILLqTtg9R0wNSQ0KgkqaKI1V7k8PP4CyGcjSC/ExEIMpXLND0IPVh1 HdrAVBVS49OAK84LS7mR2dGr7f/chSRHpvpgFz+UNdCAfefaQfzhKOEaKpi1+twHxBFLkLqWr7EkQ PcpKBsXqNm2JZIYDO6JFYO7vSVLIcR/FJqfwxX9P36SYoMR3hSjs3ZoZQBApSlzv+a/sDkp7kgx28 U0JsQXBiIs2RI5LpcpgyMvUTAbV86cY63+D9FNIzijIYj9am5Z/u1xFDtSwDejSwmOxw4ZHU1AH0U YeSO3HRZKrG8YA==; In-Reply-To: <77CBB14F-094D-48DA-A7D1-ED9E1F43DAD3@gmail.com> (message from Yuan Fu on Fri, 3 Jan 2025 23:33:25 -0800) X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list 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-mx.org@gnu.org Original-Sender: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane-mx.org@gnu.org Xref: news.gmane.io gmane.emacs.bugs:298342 Archived-At: > From: Yuan Fu > Date: Fri, 3 Jan 2025 23:33:25 -0800 > Cc: Peter Oliver , > 75310@debbugs.gnu.org > > > On Jan 3, 2025, at 7:27 AM, Eli Zaretskii wrote: > > > >> Date: Fri, 3 Jan 2025 14:47:53 +0000 (GMT) > >> From: Peter Oliver > >> cc: 75310@debbugs.gnu.org > >> > >> On Fri, 3 Jan 2025, Eli Zaretskii wrote: > >> > >>> IOW, can you show a minimal recipe for reproducing the problem, > >>> starting from "emacs -Q"? > >> > >> $ src/emacs -Q --batch --eval "(progn (message emacs-version) (require 'cl) (require 'treesit))" > >> 31.0.50 > >> Package cl is deprecated > >> lisp/treesit.el: Warning: ‘loop’ is an obsolete alias (as of 27.1); use ‘cl-loop’ instead. > > > > Thanks. > > > > Yuan, I think it would be good to rename 'loop' there to some other > > name, do you agree? > > I would definitely agree. I’ve always used cl-loop (and now I try to not use it for new code). The only instance of “loop” I can find in treesit.el is in a named-let in treesit-transpose-sexps wriiten by Theo, and it’s not the CL loop but a local function defined by named-let. I wanted to rewrite it so it doesn’t use named-let because it’s not very readable, but tbh I haven’t find the time to understand that function well enough to rewrite it (because it’s not very readable :-) > > It could be that only I can’t understand it, but code should be simple enough that even I can understand ;-) Renaming the symbol is easy, and doesn't require you to understand the code completely. We don't have to use cl-loop.