mirror of
git://git.sv.gnu.org/emacs.git
synced 2025-12-06 06:20:55 -08:00
Fix M-x completion-predicate under python-ts-mode
* lisp/progmodes/python.el (python--completion-predicate) (python-shell--completion-predicate): Filter M-x completion based on python-base-mode instead of python-mode. This allows for python-ts-mode as well (bug#63552).
This commit is contained in:
parent
1e57b2b4c7
commit
d879847cd4
1 changed files with 2 additions and 2 deletions
|
|
@ -4967,7 +4967,7 @@ the if condition."
|
||||||
(defun python--completion-predicate (_ buffer)
|
(defun python--completion-predicate (_ buffer)
|
||||||
(provided-mode-derived-p
|
(provided-mode-derived-p
|
||||||
(buffer-local-value 'major-mode buffer)
|
(buffer-local-value 'major-mode buffer)
|
||||||
'python-mode))
|
'python-base-mode))
|
||||||
|
|
||||||
(defmacro python-skeleton-define (name doc &rest skel)
|
(defmacro python-skeleton-define (name doc &rest skel)
|
||||||
"Define a `python-mode' skeleton using NAME DOC and SKEL.
|
"Define a `python-mode' skeleton using NAME DOC and SKEL.
|
||||||
|
|
@ -6791,7 +6791,7 @@ implementations: `python-mode' and `python-ts-mode'."
|
||||||
(defun python-shell--completion-predicate (_ buffer)
|
(defun python-shell--completion-predicate (_ buffer)
|
||||||
(provided-mode-derived-p
|
(provided-mode-derived-p
|
||||||
(buffer-local-value 'major-mode buffer)
|
(buffer-local-value 'major-mode buffer)
|
||||||
'python-mode 'inferior-python-mode))
|
'python-base-mode 'inferior-python-mode))
|
||||||
|
|
||||||
;; Commands that only make sense in the Python shell or when editing
|
;; Commands that only make sense in the Python shell or when editing
|
||||||
;; Python code.
|
;; Python code.
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue