From 65dfdd5c4a18d534be4d44a53a09f3427e17a62f Mon Sep 17 00:00:00 2001 From: Nikita Bloshchanevich Date: Tue, 15 Dec 2020 14:28:19 +0100 Subject: [PATCH 1/2] [4415] remove FIXME comment Due to `ivy-call' still causing files to be opened in the background (which is not a bug in `ivy'), `+emacs-lisp-lookup-definition' still needs to return `deferred' for modules. The comment is as such misleading and needs to be removed (it has been resolved). --- modules/lang/emacs-lisp/autoload.el | 2 -- 1 file changed, 2 deletions(-) diff --git a/modules/lang/emacs-lisp/autoload.el b/modules/lang/emacs-lisp/autoload.el index d85ec57f6..01c53a87a 100644 --- a/modules/lang/emacs-lisp/autoload.el +++ b/modules/lang/emacs-lisp/autoload.el @@ -61,8 +61,6 @@ to a pop up buffer." (defun +emacs-lisp-lookup-definition (_thing) "Lookup definition of THING." (if-let (module (+emacs-lisp--module-at-point)) - ;; FIXME: this is probably a bug in `counsel'. See - ;; https://github.com/abo-abo/swiper/pull/2752. (progn (doom/help-modules (car module) (cadr module) 'visit-dir) 'deferred) (call-interactively #'elisp-def))) From e05d804f1f1d983b28d3fa1ad947ca564f856ba5 Mon Sep 17 00:00:00 2001 From: Nikita Bloshchanevich Date: Fri, 26 Feb 2021 22:06:41 +0100 Subject: [PATCH 2/2] Restore the old buffer when using `ivy-call' Without `deferred', the file selected in the `counsel-find-file' will only remain the current buffer afterwards when pressing RET on an item, not just `ivy-call'. --- modules/lang/emacs-lisp/autoload.el | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/modules/lang/emacs-lisp/autoload.el b/modules/lang/emacs-lisp/autoload.el index 01c53a87a..b7257add7 100644 --- a/modules/lang/emacs-lisp/autoload.el +++ b/modules/lang/emacs-lisp/autoload.el @@ -61,7 +61,7 @@ to a pop up buffer." (defun +emacs-lisp-lookup-definition (_thing) "Lookup definition of THING." (if-let (module (+emacs-lisp--module-at-point)) - (progn (doom/help-modules (car module) (cadr module) 'visit-dir) 'deferred) + (doom/help-modules (car module) (cadr module) 'visit-dir) (call-interactively #'elisp-def))) ;;;###autoload