summaryrefslogtreecommitdiff
path: root/lisp/textmodes/ispell.el
diff options
context:
space:
mode:
authorMark Diekhans <markd@ucsc.edu>2019-02-24 10:27:09 -0800
committerEli Zaretskii <eliz@gnu.org>2019-03-08 11:17:46 +0200
commit0dbc4a697afb2a1e409909289f608fd4da875c24 (patch)
tree39ca0e5a406b2ef074c6005602c1a75107eb306a /lisp/textmodes/ispell.el
parentab9ae2fdfd24f93a9dfa7b1e0567b6a29962b55c (diff)
downloademacs-0dbc4a697afb2a1e409909289f608fd4da875c24.tar.gz
Improve ispell.el diagnostics if Hunspell dictionaries aren't found
* lisp/textmodes/ispell.el (ispell-set-spellchecker-params): Set ispell-last-program-name only at the end, so as to produce useful diagnostics when Hunspell dictionaries are not found. (Bug#34640) Copyright-paperwork-exempt: yes
Diffstat (limited to 'lisp/textmodes/ispell.el')
-rw-r--r--lisp/textmodes/ispell.el4
1 files changed, 2 insertions, 2 deletions
diff --git a/lisp/textmodes/ispell.el b/lisp/textmodes/ispell.el
index 35dae7bc432..6553a2799bb 100644
--- a/lisp/textmodes/ispell.el
+++ b/lisp/textmodes/ispell.el
@@ -1273,7 +1273,6 @@ aspell is used along with Emacs).")
(defun ispell-set-spellchecker-params ()
"Initialize some spellchecker parameters when changed or first used."
(unless (eq ispell-last-program-name ispell-program-name)
- (setq ispell-last-program-name ispell-program-name)
(ispell-kill-ispell t)
(if (and (condition-case ()
(progn
@@ -1388,7 +1387,8 @@ aspell is used along with Emacs).")
(nth 7 adict)))
adict)
tmp-dicts-alist :test #'equal))
- (setq ispell-dictionary-alist tmp-dicts-alist))))
+ (setq ispell-dictionary-alist tmp-dicts-alist)))
+ (setq ispell-last-program-name ispell-program-name))
(defun ispell-valid-dictionary-list ()
"Return a list of valid dictionaries.