emacs-diffs
[Top][All Lists]
Advanced

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

[Emacs-diffs] [emacs] 01/01: Backport Use derived-mode-p in python.el in


From: Ivan Andrus
Subject: [Emacs-diffs] [emacs] 01/01: Backport Use derived-mode-p in python.el instead of equality test with major-mode
Date: Sat, 15 Nov 2014 04:58:31 +0000

gvol pushed a commit to branch emacs-24
in repository emacs.

commit 15ec2d7cffe5f0eb4c073ef7b446a654fb8419e4
Author: Ivan Andrus <address@hidden>
Date:   Sat Nov 1 12:33:02 2014 -0600

    Backport Use derived-mode-p in python.el instead of equality test with 
major-mode
    
    Fixes: debbugs:18854
    
    * progmodes/python.el (python-ffap-module-path): Use
    `derived-mode-p' instead of equality test on `major-mode'.
---
 lisp/ChangeLog           |    5 +++++
 lisp/progmodes/python.el |    2 +-
 2 files changed, 6 insertions(+), 1 deletions(-)

diff --git a/lisp/ChangeLog b/lisp/ChangeLog
index ce4221f..a6ab3b8 100644
--- a/lisp/ChangeLog
+++ b/lisp/ChangeLog
@@ -1,3 +1,8 @@
+2014-11-14  Ivan Andrus  <address@hidden>
+
+       * progmodes/python.el (python-ffap-module-path): Use
+       `derived-mode-p' instead of equality test on `major-mode'.
+
 2014-11-13  Ulrich Müller  <address@hidden>
 
        * version.el (emacs-repository-get-version): Call `git log'
diff --git a/lisp/progmodes/python.el b/lisp/progmodes/python.el
index c828de1..95fc52d 100644
--- a/lisp/progmodes/python.el
+++ b/lisp/progmodes/python.el
@@ -3281,7 +3281,7 @@ The skeleton will be bound to python-skeleton-NAME."
 (defun python-ffap-module-path (module)
   "Function for `ffap-alist' to return path for MODULE."
   (let ((process (or
-                  (and (eq major-mode 'inferior-python-mode)
+                  (and (derived-mode-p 'inferior-python-mode)
                        (get-buffer-process (current-buffer)))
                   (python-shell-get-process))))
     (if (not process)



reply via email to

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