Remove remaining Emacs27+ checks

- Remove remaining `EMACS27+` checks, since the whole codebase is
  assumed to run at version 27 or above now
- Remove `EMACS27+` definition since it's no longer needed
This commit is contained in:
Itai Y. Efrat 2021-07-10 15:52:19 +03:00
parent ba716d69f0
commit 34fae1c01c
8 changed files with 24 additions and 54 deletions

View file

@ -165,13 +165,8 @@ Dictionary.app behind the scenes to get definitions.")
:when (featurep! :completion ivy)
:config
(set-popup-rule! "^\\*xref\\*$" :ignore t)
;; xref initialization is different in Emacs 27 - there are two different
;; variables which can be set rather than just one
(when EMACS27+
(setq xref-show-definitions-function #'ivy-xref-show-defs))
;; Necessary in Emacs <27. In Emacs 27 it will affect all xref-based
;; commands other than xref-find-definitions too (eg project-find-regexp)
(setq xref-show-xrefs-function #'ivy-xref-show-xrefs)
(setq xref-show-definitions-function #'ivy-xref-show-defs
xref-show-xrefs-function #'ivy-xref-show-xrefs)
;; HACK Fix #4386: `ivy-xref-show-xrefs' calls `fetcher' twice, which has
;; side effects that breaks in some cases (i.e. on `dired-do-find-regexp').