emacs-elpa-diffs
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[elpa] master 387b4d1 106/173: Fix "obsolete function" warning


From: Dmitry Gutov
Subject: [elpa] master 387b4d1 106/173: Fix "obsolete function" warning
Date: Thu, 23 Jun 2016 00:28:42 +0000 (UTC)

branch: master
commit 387b4d12ef61c3d94d1ead49e394ef399b17a02c
Author: Dmitry Gutov <address@hidden>
Commit: Dmitry Gutov <address@hidden>

    Fix "obsolete function" warning
    
    Fixes #435
---
 company-ispell.el |   12 +++++++++---
 1 file changed, 9 insertions(+), 3 deletions(-)

diff --git a/company-ispell.el b/company-ispell.el
index 91f43df..581ff48 100644
--- a/company-ispell.el
+++ b/company-ispell.el
@@ -41,11 +41,16 @@ If nil, use `ispell-complete-word-dict'."
 
 (defvar company-ispell-available 'unknown)
 
+(defalias 'company-ispell--lookup-words
+  (if (fboundp 'ispell-lookup-words)
+      'ispell-lookup-words
+    'lookup-words))
+
 (defun company-ispell-available ()
   (when (eq company-ispell-available 'unknown)
     (condition-case err
         (progn
-          (lookup-words "WHATEVER")
+          (company-ispell--lookup-words "WHATEVER")
           (setq company-ispell-available t))
       (error
        (message "Company: ispell-look-command not found")
@@ -61,8 +66,9 @@ If nil, use `ispell-complete-word-dict'."
     (prefix (when (company-ispell-available)
               (company-grab-word)))
     (candidates
-     (let ((words (lookup-words arg (or company-ispell-dictionary
-                                        ispell-complete-word-dict)))
+     (let ((words (company-ispell--lookup-words
+                   arg
+                   (or company-ispell-dictionary ispell-complete-word-dict)))
            (completion-ignore-case t))
        (if (string= arg "")
            ;; Small optimization.



reply via email to

[Prev in Thread] Current Thread [Next in Thread]