GNU bug report logs - #71537
30.0.50; [PATCH] missing autoload cookies

Previous Next

Package: emacs;

Reported by: Gerard Vermeulen <gerard.vermeulen <at> posteo.net>

Date: Thu, 13 Jun 2024 15:00:02 UTC

Severity: normal

Tags: patch

Found in version 30.0.50

Done: Eli Zaretskii <eliz <at> gnu.org>

Bug is archived. No further changes may be made.

Full log


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

From: Eli Zaretskii <eliz <at> gnu.org>
To: Gerard Vermeulen <gerard.vermeulen <at> posteo.net>
Cc: 71537 <at> debbugs.gnu.org
Subject: Re: bug#71537: 30.0.50; [PATCH] missing autoload cookies
Date: Thu, 13 Jun 2024 18:33:37 +0300
> Date: Thu, 13 Jun 2024 14:59:06 +0000
> From: Gerard Vermeulen <gerard.vermeulen <at> posteo.net>
> 
> I propose the attached patch adding three missing autoload cookies
> to eliminate two require forms from two sections in my init.el.
> 
> To eliminate (require 'shortdoc) from the first section:
> (with-eval-after-load 'help-fns
>    ;; ChatGPT recommends to require `shortdoc' contrary to the
>    ;; `shortdoc-help-fns-examples-function' documentation string.
>    (require 'shortdoc)
>    (add-hook 'help-fns-describe-function-functions
>              #'shortdoc-help-fns-examples-function)
>    (setopt help-enable-symbol-autoload t))
> 
> And to eliminate (require 'pulse) from the second section:
> (require 'pulse) ; since `pulse' does not autoload `pulse-delay' and
>                   ; `pulse-iterations'.
> 
> (defun flash-line-around-point (&rest _)
>    "Flash the line around point."
>    (let ((pulse-iterations 16)
>          (pulse-delay 0.1))
>      (pulse-momentary-highlight-one-line (point))))
> 
> (dolist (command '(scroll-up-command
>                     scroll-down-command
>                     recenter-top-bottom
>                     other-window))
>    (advice-add command :after #'flash-line-around-point))

Thanks, but I don't understand why what we have now constitutes a
problem.  help-fns loads shortdoc when it needs it, and
pulse-momentary-highlight-one-line is autoloaded already (you don't
need to auto-load variables to assign values to them).

Can you describe the problems you have if you delete those 'require's
from your init file, and explain why manually requiring them is a
problem?




This bug report was last modified 1 year and 33 days ago.

Previous Next


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