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

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

[nongnu] elpa/haskell-tng-mode 19c03cc 254/385: company-mode shouldn't f


From: ELPA Syncer
Subject: [nongnu] elpa/haskell-tng-mode 19c03cc 254/385: company-mode shouldn't force an hsinspect call
Date: Tue, 5 Oct 2021 23:59:42 -0400 (EDT)

branch: elpa/haskell-tng-mode
commit 19c03cc29480fe1cdfff0a552b796fe9210e071e
Author: Tseen She <ts33n.sh3@gmail.com>
Commit: Tseen She <ts33n.sh3@gmail.com>

    company-mode shouldn't force an hsinspect call
---
 haskell-tng-contrib-company.el | 2 +-
 haskell-tng-hsinspect.el       | 4 ++--
 2 files changed, 3 insertions(+), 3 deletions(-)

diff --git a/haskell-tng-contrib-company.el b/haskell-tng-contrib-company.el
index 4d78e98..e436220 100644
--- a/haskell-tng-contrib-company.el
+++ b/haskell-tng-contrib-company.el
@@ -54,7 +54,7 @@
      ;;(message "TNG asked with %S" arg)
      (seq-mapcat
       (lambda (names) (all-completions arg (seq-map #'cdr names)))
-      (haskell-tng--hsinspect-imports)))
+      (haskell-tng--hsinspect-imports 'lookup-only)))
     ('sorted t)
     ('duplicates t)
     ;; TODO 'meta return the FQN
diff --git a/haskell-tng-hsinspect.el b/haskell-tng-hsinspect.el
index 435987d..5e12793 100644
--- a/haskell-tng-hsinspect.el
+++ b/haskell-tng-hsinspect.el
@@ -80,8 +80,8 @@ change."
 (defvar-local haskell-tng--hsinspect-imports nil
   "Cache for the last `imports' call for this buffer.
 t means the process failed.")
-(defun haskell-tng--hsinspect-imports ()
-  (if haskell-tng--hsinspect-imports
+(defun haskell-tng--hsinspect-imports (&optional lookup-only)
+  (if (or lookup-only haskell-tng--hsinspect-imports)
       (unless (eq t haskell-tng--hsinspect-imports)
         haskell-tng--hsinspect-imports)
     (setq haskell-tng--hsinspect-imports t) ;; avoid races



reply via email to

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