]> git.eshelyaron.com Git - emacs.git/commitdiff
* lisp/emulation/viper.el (viper-set-hooks): Replace obsolete func.
authorGlenn Morris <rgm@gnu.org>
Sat, 24 Mar 2018 00:55:51 +0000 (20:55 -0400)
committerAndrew G Cohen <cohen@andy.bu.edu>
Tue, 11 Dec 2018 06:18:30 +0000 (14:18 +0800)
lisp/emulation/viper.el

index c8eca30e88b0906d71845f0ddcdea8f322334fa1..8604020b987ad9ba7b5e5481458f00f1568a7692 100644 (file)
@@ -937,8 +937,13 @@ Two differences:
     (if (and (eq viper-current-state 'vi-state)
             ;; Do not use called-interactively-p here. XEmacs does not have it
             ;; and interactive-p is just fine.
-            ;; (called-interactively-p 'interactive))
-            (interactive-p))
+             (if (featurep 'xemacs)
+                 (interactive-p)
+               ;; Respect the spirit of the above comment, though it
+               ;; seems pointless, since XE doesn't have advice-add or
+               ;; lexical binding or any other of the newer features
+               ;; this file uses.
+               (called-interactively-p 'interactive)))
        (beep 1)
       (apply orig-fun args))))