Function: python-shell-completion-native-turn-on-maybe
python-shell-completion-native-turn-on-maybe is an interactive and
byte-compiled function defined in python.el.gz.
Signature
(python-shell-completion-native-turn-on-maybe &optional MSG)
Documentation
Turn on native completions if enabled and available.
With argument MSG show activation/deactivation message.
Key Bindings
Source Code
;; Defined in /usr/src/emacs/lisp/progmodes/python.el.gz
(defun python-shell-completion-native-turn-on-maybe (&optional msg)
"Turn on native completions if enabled and available.
With argument MSG show activation/deactivation message."
(interactive "p")
(python-shell-with-shell-buffer
(when python-shell-completion-native-enable
(cond
((python-shell-completion-native-interpreter-disabled-p)
(python-shell-completion-native-turn-off msg))
((and python-shell-readline-completer-delims
(python-shell-completion-native-setup))
(when msg
(message "Shell native completion is enabled.")))
(t
(when msg
(message (concat "Python does not use GNU readline;"
" no completion in multi-line commands.")))
(python-shell-completion-native-turn-off nil))))))