bug-gnu-emacs
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

bug#62767: 29.0.90; [PATCH] *lisp/emacs-lisp/package.el: set variables a


From: Philip Kaludercic
Subject: bug#62767: 29.0.90; [PATCH] *lisp/emacs-lisp/package.el: set variables after info package
Date: Mon, 17 Apr 2023 16:03:56 +0000

lin Sun <sunlin7@yahoo.com> writes:

> Hi Philip,
>
>> How did you come to the conclusion about the second one?
> The 2nd one is necessary because the following lines will use the full
> `Info-directory-list` to print its values into the
> package-quickstart.el, whose value was modified by the function
> `package-activate'.
> If I comment out or use the `eval-after-load` on the 2nd one, the
> `Info-directory-list` will be empty, and missed in the
> package-quickstart.el file.

OK, I get it now.  I was confused because it seemed as though
`Info-directory-list' could just be bound and declared using a defvar
before the function, but if we do not load info then the
with-eval-after-load blocks in `package-activate-1' that are invoked for
the side effect of manipulating `Info-directory-list' do not get
evaluated, which is why we see that the value is empty.

But as the function `package-quickstart-refresh' is not invoked on
startup, but as `package-quickstart' says

    This requires the use of `package-quickstart-refresh' every time the
    activations need to be changed, such as when `package-load-list' is
    modified.

This should be fine.

> Hi Ruijie,
>
>> "insure" -> "ensure"?
> You're right.
> I had fixed my typo in the patch file (only typo in comment), and
> attached the new one, please help review again. Thanks

Again, assuming that there is no issue with `with-eval-after-load', the
code should be fine.  The commit message looks a bit distorted though?
Did you generate it using C-c C-w?  I get this template when I apply
your commit:

* lisp/emacs-lisp/package.el (package-activate-1):
(package-quickstart-refresh):

Also, it would make sense to motivate the changes in more detail.  What
do the changes improve?





reply via email to

[Prev in Thread] Current Thread [Next in Thread]