GNU bug report logs - #21440
25.0.50; Manual: FEATURE-unload-hook in (info "(elisp) Coding Conventions")

Previous Next

Package: emacs;

Reported by: Michael Heerdegen <michael_heerdegen <at> web.de>

Date: Wed, 9 Sep 2015 11:44:02 UTC

Severity: minor

Found in version 25.0.50

Fixed in version 28.1

Done: Lars Ingebrigtsen <larsi <at> gnus.org>

Bug is archived. No further changes may be made.

Full log


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

From: Michael Heerdegen <michael_heerdegen <at> web.de>
To: Lars Ingebrigtsen <larsi <at> gnus.org>
Cc: michael.albinus <at> gmx.de, 21440 <at> debbugs.gnu.org, stefan <at> marxist.se
Subject: Re: bug#21440: 25.0.50; Manual: FEATURE-unload-hook in (info
 "(elisp) Coding Conventions")
Date: Sat, 17 Jul 2021 03:35:09 +0200
Michael Heerdegen <michael_heerdegen <at> web.de> writes:

> > Hm...  does unload-feature remove advices?  Let's see..
> >
> > Well, there's this:
> >
> > (defun loadhist--unload-function (x)
> > [...]
> >
> > Hm...  but is that what it does?
>
> I don't think so.  AFAIU this does not even effect nadvice advices,
> and treats only advises of functions defined by the feature.

Here is a simple test file:

#+begin_src emacs-lisp
;;; foo.el --- ...  -*- lexical-binding: t -*-

(defun my-foo--around-ad (f &rest args)
  17
  (apply f args))

(advice-add 'make-frame-command :around #'my-foo--around-ad)

(provide 'foo)
;;; foo.el ends here
#+end_src

Load it, then M-x unload-feature foo RET -- and after that, C-x 5 2
errors.


Michael.




This bug report was last modified 3 years and 308 days ago.

Previous Next


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