diff options
| author | Clément Pit--Claudel | 2016-10-26 22:46:28 -0400 |
|---|---|---|
| committer | Clément Pit--Claudel | 2016-10-31 08:35:33 -0400 |
| commit | dbb341022870ecad4c9177485a6770a355633cc0 (patch) | |
| tree | a210fce9fa559b08b7a53e8c890cdfbca95c04dd /lisp/progmodes/python.el | |
| parent | 91c97b6eed708f5a1f34478b52f42ef9e51efcb5 (diff) | |
| download | emacs-dbb341022870ecad4c9177485a6770a355633cc0.tar.gz emacs-dbb341022870ecad4c9177485a6770a355633cc0.zip | |
python.el: Fix detection of native completion in Python 3 (bug #24401)
With Python 3.5, (python-shell-completion-native-get-completions ... "")
would return an empty list, causing python.el to think that native
completion was unavailable (the difference between Python 2 and Python 3
is due to https://bugs.python.org/issue25660).
* lisp/progmodes/python.el (python-shell-completion-native-try): Use "_"
to check whether native completion is available instead of "".
Diffstat (limited to 'lisp/progmodes/python.el')
| -rw-r--r-- | lisp/progmodes/python.el | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/lisp/progmodes/python.el b/lisp/progmodes/python.el index 49f7bcf5df9..3fae3987b22 100644 --- a/lisp/progmodes/python.el +++ b/lisp/progmodes/python.el | |||
| @@ -3296,7 +3296,7 @@ When a match is found, native completion is disabled." | |||
| 3296 | python-shell-completion-native-try-output-timeout)) | 3296 | python-shell-completion-native-try-output-timeout)) |
| 3297 | (python-shell-completion-native-get-completions | 3297 | (python-shell-completion-native-get-completions |
| 3298 | (get-buffer-process (current-buffer)) | 3298 | (get-buffer-process (current-buffer)) |
| 3299 | nil ""))) | 3299 | nil "_"))) |
| 3300 | 3300 | ||
| 3301 | (defun python-shell-completion-native-setup () | 3301 | (defun python-shell-completion-native-setup () |
| 3302 | "Try to setup native completion, return non-nil on success." | 3302 | "Try to setup native completion, return non-nil on success." |