[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Emacs-diffs] master 0d54f2f: * lisp/textmodes/flyspell.el (flyspell-wor
From: |
Stefan Monnier |
Subject: |
[Emacs-diffs] master 0d54f2f: * lisp/textmodes/flyspell.el (flyspell-word): Defvar. |
Date: |
Sat, 14 Feb 2015 03:45:24 +0000 |
branch: master
commit 0d54f2f51c799cc372d9521233a8009adc4c3691
Author: Stefan Monnier <address@hidden>
Commit: Stefan Monnier <address@hidden>
* lisp/textmodes/flyspell.el (flyspell-word): Defvar.
Fixes: debbugs:19844
(flyspell-generic-check-word-p): Mark as obsolete.
* lisp/erc/erc-spelling.el (erc-spelling-init):
Use flyspell-generic-check-word-predicate.
---
lisp/ChangeLog | 13 +++++++++----
lisp/erc/ChangeLog | 5 +++++
lisp/erc/erc-spelling.el | 3 ++-
lisp/textmodes/flyspell.el | 8 +++++---
4 files changed, 21 insertions(+), 8 deletions(-)
diff --git a/lisp/ChangeLog b/lisp/ChangeLog
index 030d572..257b11b 100644
--- a/lisp/ChangeLog
+++ b/lisp/ChangeLog
@@ -1,3 +1,8 @@
+2015-02-14 Stefan Monnier <address@hidden>
+
+ * textmodes/flyspell.el (flyspell-word): Defvar (bug#19844).
+ (flyspell-generic-check-word-p): Mark as obsolete.
+
2015-02-13 Artur Malabarba <address@hidden>
* emacs-lisp/package.el (package--compatibility-table): New var.
@@ -14,8 +19,8 @@
* net/sasl-scram-rfc.el: New file.
- * net/sasl.el (sasl-mechanisms): Remove SCRAM-MD5. Add
- SCRAM-SHA-1 first.
+ * net/sasl.el (sasl-mechanisms): Remove SCRAM-MD5.
+ Add SCRAM-SHA-1 first.
(sasl-mechanism-alist): Remove SCRAM-MD5 entry. Add SCRAM-SHA-1
entry (bug#17636).
@@ -34,8 +39,8 @@
python.el: Allow killing shell buffer if process is dead. (Bug#19823)
- * progmodes/python.el (python-shell-font-lock-kill-buffer): Don't
- require a running process.
+ * progmodes/python.el (python-shell-font-lock-kill-buffer):
+ Don't require a running process.
(python-shell-font-lock-post-command-hook): Fontify only if the
shell process is running.
diff --git a/lisp/erc/ChangeLog b/lisp/erc/ChangeLog
index 44971cc..4c1c843 100644
--- a/lisp/erc/ChangeLog
+++ b/lisp/erc/ChangeLog
@@ -1,3 +1,8 @@
+2015-02-14 Stefan Monnier <address@hidden>
+
+ * erc-spelling.el (erc-spelling-init):
+ Use flyspell-generic-check-word-predicate.
+
2015-01-28 Dima Kogan <address@hidden>
* erc-backend.el (define-erc-response-handler): Give hook-name
diff --git a/lisp/erc/erc-spelling.el b/lisp/erc/erc-spelling.el
index e2ddb04..0cba956 100644
--- a/lisp/erc/erc-spelling.el
+++ b/lisp/erc/erc-spelling.el
@@ -71,7 +71,7 @@ The current buffer is given by BUFFER."
(if dicts
(cadr (car dicts))
(erc-with-server-buffer ispell-local-dictionary)))))
- (setq flyspell-generic-check-word-p 'erc-spelling-flyspell-verify)
+ (setq flyspell-generic-check-word-predicate #'erc-spelling-flyspell-verify)
(flyspell-mode 1)))
(defun erc-spelling-unhighlight-word (word)
@@ -85,6 +85,7 @@ The cadr is the beginning and the caddr is the end."
(defun erc-spelling-flyspell-verify ()
"Flyspell only the input line, nothing else."
+ ;; FIXME: Don't use `flyspell-word'!
(let ((word-data (and (boundp 'flyspell-word)
flyspell-word)))
(when word-data
diff --git a/lisp/textmodes/flyspell.el b/lisp/textmodes/flyspell.el
index 91a43f0..ffaf7e7 100644
--- a/lisp/textmodes/flyspell.el
+++ b/lisp/textmodes/flyspell.el
@@ -304,8 +304,8 @@ Returns t to continue checking, nil otherwise.
Flyspell mode sets this variable to whatever is the `flyspell-mode-predicate'
property of the major mode name.")
(make-variable-buffer-local 'flyspell-generic-check-word-predicate)
-(defvaralias 'flyspell-generic-check-word-p
- 'flyspell-generic-check-word-predicate)
+(define-obsolete-variable-alias 'flyspell-generic-check-word-p
+ 'flyspell-generic-check-word-predicate "25.1")
;;*--- mail mode -------------------------------------------------------*/
(put 'mail-mode 'flyspell-mode-predicate 'mail-mode-flyspell-verify)
@@ -398,7 +398,7 @@ like <img alt=\"Some thing.\">."
"Turn on `flyspell-mode' for comments and strings."
(interactive)
(setq flyspell-generic-check-word-predicate
- 'flyspell-generic-progmode-verify)
+ #'flyspell-generic-progmode-verify)
(flyspell-mode 1)
(run-hooks 'flyspell-prog-mode-hook))
@@ -1040,6 +1040,8 @@ Mostly we check word delimiters."
(goto-char (1+ p)))))
r)))
+(defvar flyspell-word) ;Backward compatibility; some predicates made use of it!
+
;;*---------------------------------------------------------------------*/
;;* flyspell-word ... */
;;*---------------------------------------------------------------------*/
[Prev in Thread] |
Current Thread |
[Next in Thread] |
- [Emacs-diffs] master 0d54f2f: * lisp/textmodes/flyspell.el (flyspell-word): Defvar.,
Stefan Monnier <=