branch: externals/corfu
commit ec6d21a939a5449377bebeb68cb33ef566c5c296
Author: Daniel Mendler <m...@daniel-mendler.de>
Commit: Daniel Mendler <m...@daniel-mendler.de>

    corfu-popupinfo: Delay mode hooks for file preview
---
 extensions/corfu-popupinfo.el | 7 ++++++-
 1 file changed, 6 insertions(+), 1 deletion(-)

diff --git a/extensions/corfu-popupinfo.el b/extensions/corfu-popupinfo.el
index e5e1a38d07..08e0246139 100644
--- a/extensions/corfu-popupinfo.el
+++ b/extensions/corfu-popupinfo.el
@@ -157,7 +157,12 @@ all values are in pixels relative to the origin. See
                 ;; BUG: company-location may throw errors if location is not 
found
                 (loc (ignore-errors (funcall fun candidate)))
                 (buf (or (and (bufferp (car loc)) (car loc))
-                         (find-file-noselect (car loc) t))))
+                         (let ((inhibit-message . t)
+                               (enable-dir-local-variables . nil)
+                               (enable-local-variables . :safe)
+                               (non-essential . t)
+                               (delay-mode-hooks . t))
+                           (find-file-noselect (car loc) t)))))
       (unwind-protect
           (with-current-buffer buf
             (save-excursion

Reply via email to