Fix #3827: void-variable flyspell-delayed-commands

This occurs in org-compat.el:

  (eval-after-load "flyspell"
    '(add-to-list 'flyspell-delayed-commands 'org-self-insert-command))

By not using a package symbol, this code runs whenever any file named
flyspell.el is loaded. Guess what one of the :checkers spell module's
autoloads files is named? flyspell.el
This commit is contained in:
Henrik Lissner 2020-08-26 19:31:09 -04:00
parent 848cc117c4
commit bfd71a8bb9
No known key found for this signature in database
GPG key ID: 5F6C0EA160557395
2 changed files with 6 additions and 6 deletions

View file

@ -1,4 +1,4 @@
;;; checkers/spell/autoload/flyspell.el -*- lexical-binding: t; -*-
;;; checkers/spell/autoload/+flyspell.el -*- lexical-binding: t; -*-
;;;###if (featurep! +flyspell)
;;;###autodef

View file

@ -1,4 +1,4 @@
;;; checkers/spell/autoload/spell-fu.el -*- lexical-binding: t; -*-
;;; checkers/spell/autoload/+spell-fu.el -*- lexical-binding: t; -*-
;;;###if (not (featurep! +flyspell))
(defun +spell--correct (replace poss word orig-pt start end)
@ -50,10 +50,10 @@
(defun +spell/correct ()
"Correct spelling of word at point."
(interactive)
;; We fake awareness for our personal dictionary by stopping short if spell-fu
;; hasn't highlighted the current word. This is necessary because
;; ispell/aspell struggles to find our `ispell-personal-dictionary' if it's
;; not in $HOME.
;; HACK Fake awareness for our personal dictionary by stopping short if
;; spell-fu hasn't highlighted the current word. This is necessary
;; because ispell/aspell struggles to find our
;; `ispell-personal-dictionary' if it's not in $HOME.
(unless (memq 'spell-fu-incorrect-face (face-at-point nil t))
(user-error "%S is correct" (thing-at-point 'word t)))
(ispell-set-spellchecker-params)