From: Eli Zaretskii <eliz@gnu.org>
To: Yuan Fu <casouri@gmail.com>
Cc: p.d.oliver@mavit.org.uk, 75310@debbugs.gnu.org
Subject: bug#75310: Eliminate obsolete alias warning
Date: Sat, 04 Jan 2025 22:03:42 +0200 [thread overview]
Message-ID: <86cyh2bb35.fsf@gnu.org> (raw)
In-Reply-To: <94CBEFD3-6E58-4056-B73C-B5FC6AB6E1B9@gmail.com> (message from Yuan Fu on Sat, 4 Jan 2025 11:26:38 -0800)
> From: Yuan Fu <casouri@gmail.com>
> Date: Sat, 4 Jan 2025 11:26:38 -0800
> Cc: Peter Oliver <p.d.oliver@mavit.org.uk>,
> 75310@debbugs.gnu.org
>
>
>
> > On Jan 4, 2025, at 12:29 AM, Eli Zaretskii <eliz@gnu.org> wrote:
> >
> >> From: Yuan Fu <casouri@gmail.com>
> >> Date: Fri, 3 Jan 2025 23:33:25 -0800
> >> Cc: Peter Oliver <p.d.oliver@mavit.org.uk>,
> >> 75310@debbugs.gnu.org
> >>
> >>> On Jan 3, 2025, at 7:27 AM, Eli Zaretskii <eliz@gnu.org> wrote:
> >>>
> >>>> Date: Fri, 3 Jan 2025 14:47:53 +0000 (GMT)
> >>>> From: Peter Oliver <p.d.oliver@mavit.org.uk>
> >>>> 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.
>
> Ah right, duh :-) Though I renamed the symbol and still gets the deprecation message. There’s no other “loop” in treesit.el, only cl-loop. Could you maybe take a look?
You get deprecation message in what scenario? If you see
Package cl is deprecated
when you load cl, that's expected, and cannot be shut up. The message
we want to avoid is this:
lisp/treesit.el: Warning: ‘loop’ is an obsolete alias (as of 27.1); use ‘cl-loop’ instead.
Are you still seeing it after the change?
prev parent reply other threads:[~2025-01-04 20:03 UTC|newest]
Thread overview: 12+ messages / expand[flat|nested] mbox.gz Atom feed top
2025-01-03 11:41 bug#75310: Eliminate obsolete alias warning Peter Oliver
2025-01-03 12:02 ` Eli Zaretskii
2025-01-03 14:11 ` Peter Oliver
2025-01-03 14:17 ` Eli Zaretskii
2025-01-03 14:47 ` Peter Oliver
2025-01-03 15:27 ` Eli Zaretskii
2025-01-04 7:33 ` Yuan Fu
2025-01-04 8:29 ` Eli Zaretskii
2025-01-04 19:26 ` Yuan Fu
2025-01-04 19:27 ` Yuan Fu
2025-01-04 19:31 ` Yuan Fu
2025-01-04 20:03 ` Eli Zaretskii [this message]
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
List information: https://www.gnu.org/software/emacs/
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=86cyh2bb35.fsf@gnu.org \
--to=eliz@gnu.org \
--cc=75310@debbugs.gnu.org \
--cc=casouri@gmail.com \
--cc=p.d.oliver@mavit.org.uk \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
Code repositories for project(s) associated with this public inbox
https://git.savannah.gnu.org/cgit/emacs.git
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).