emacs-diffs
[Top][All Lists]
Advanced

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

[Emacs-diffs] master 01f3753: Fix broken viper deactivation


From: Phillip Lord
Subject: [Emacs-diffs] master 01f3753: Fix broken viper deactivation
Date: Fri, 27 May 2016 15:49:45 +0000 (UTC)

branch: master
commit 01f375386d74af896d427e2c6899df20c78b3850
Author: Phillip Lord <address@hidden>
Commit: Phillip Lord <address@hidden>

    Fix broken viper deactivation
    
    * lisp/emulation/viper.el (viper--deactivate-advice-list): Destructure
      args to advice-remove.
      (viper--advice-add): Use cons not list.
    
    Addresses bug#23625
---
 lisp/emulation/viper.el |    8 ++++++--
 1 file changed, 6 insertions(+), 2 deletions(-)

diff --git a/lisp/emulation/viper.el b/lisp/emulation/viper.el
index a0bba9a..1ee1464 100644
--- a/lisp/emulation/viper.el
+++ b/lisp/emulation/viper.el
@@ -647,10 +647,14 @@ This startup message appears whenever you load Viper, 
unless you type `y' now."
 
 (defun viper--advice-add (function where advice)
   (advice-add function where advice)
-  (push (list function advice) viper--advice-list))
+  (push (cons function advice) viper--advice-list))
 
 (defun viper--deactivate-advice-list ()
-  (mapc #'advice-remove viper--advice-list)
+  (mapc (lambda (n)
+          (advice-remove
+           (car n)
+           (cdr n)))
+        viper--advice-list)
   (setq viper--advice-list nil))
 
 (defun viper-go-away ()



reply via email to

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