GNU bug report logs - #71354
Replace anonymous lambda timers with named functions for better tracing

Previous Next

Package: emacs;

Reported by: Matthew Bauer <mjbauer95 <at> gmail.com>

Date: Tue, 4 Jun 2024 03:35:02 UTC

Severity: normal

Tags: patch

To reply to this bug, email your comments to 71354 AT debbugs.gnu.org.

Toggle the display of automated, internal messages from the tracker.

View this report as an mbox folder, status mbox, maintainer mbox


Report forwarded to bug-gnu-emacs <at> gnu.org:
bug#71354; Package emacs. (Tue, 04 Jun 2024 03:35:02 GMT) Full text and rfc822 format available.

Acknowledgement sent to Matthew Bauer <mjbauer95 <at> gmail.com>:
New bug report received and forwarded. Copy sent to bug-gnu-emacs <at> gnu.org. (Tue, 04 Jun 2024 03:35:02 GMT) Full text and rfc822 format available.

Message #5 received at submit <at> debbugs.gnu.org (full text, mbox):

From: Matthew Bauer <mjbauer95 <at> gmail.com>
To: bug-gnu-emacs <at> gnu.org
Subject: Replace anonymous lambda timers with named functions for better
 tracing
Date: Mon, 03 Jun 2024 22:34:18 -0500
[Message part 1 (text/plain, inline)]
Tags: patch


I noticed a few timers found in ‘M-x list-timers’ were anonymous lambdas
that show up like this:

   *           0.5s            t #<subr F616e6f6e796d6f75732d6c616d626461_anonymous_lambda_9>

That’s not particularly helpful when trying to figure out what timers
are being run. I tracked down the two that I have configured to eldoc
and jit-lock. This gives them names that can be traced.


In GNU Emacs 30.0.50 (build 1, aarch64-apple-darwin23.5.0, NS
appkit-2487.60 Version 14.5 (Build 23F79))
Repository revision: 0cb511b33bc96fc30d8e5286a474b4eea54817e3
Repository branch: master
Windowing system distributor 'Apple', version 10.3.2487
System Description:  macOS 14.5

Configured using:
 'configure
 --prefix=/nix/store/bj6mdh15nkgh2xbdzzsly43m9q7mi0zp-emacs-git-20240531.0
 --disable-build-details --with-modules --disable-ns-self-contained
 --with-ns --with-compress-install --with-toolkit-scroll-bars
 --with-native-compilation --without-imagemagick --with-mailutils
 --without-small-ja-dic --with-tree-sitter --without-xinput2
 --without-xwidgets --without-dbus --without-selinux'

[remove-anonymous-timer-lambdas.patch (text/patch, attachment)]

Information forwarded to bug-gnu-emacs <at> gnu.org:
bug#71354; Package emacs. (Tue, 04 Jun 2024 08:23:02 GMT) Full text and rfc822 format available.

Message #8 received at 71354 <at> debbugs.gnu.org (full text, mbox):

From: Andrea Corallo <acorallo <at> gnu.org>
To: Matthew Bauer <mjbauer95 <at> gmail.com>
Cc: 71354 <at> debbugs.gnu.org
Subject: Re: bug#71354: Replace anonymous lambda timers with named functions
 for better tracing
Date: Tue, 04 Jun 2024 04:22:08 -0400
Matthew Bauer <mjbauer95 <at> gmail.com> writes:

> Tags: patch
>
>
> I noticed a few timers found in ‘M-x list-timers’ were anonymous lambdas
> that show up like this:
>
>    *           0.5s            t #<subr F616e6f6e796d6f75732d6c616d626461_anonymous_lambda_9>
>
> That’s not particularly helpful when trying to figure out what timers
> are being run. I tracked down the two that I have configured to eldoc
> and jit-lock. This gives them names that can be traced.

I'm okay with the change.  Another fix maybe more general would have
having more information in the subr name.  I think Alan is working on
this in bug#66750 but I suspect it will not go in for emacs 30.

  Andrea




This bug report was last modified 135 days ago.

Previous Next


GNU bug tracking system
Copyright (C) 1999 Darren O. Benham, 1997,2003 nCipher Corporation Ltd, 1994-97 Ian Jackson.