summary refs log tree commit diff stats
diff options
context:
space:
mode:
-rw-r--r--init.el16
1 files changed, 5 insertions, 11 deletions
diff --git a/init.el b/init.el index d2a8960..3e19ec0 100644 --- a/init.el +++ b/init.el
@@ -16,17 +16,6 @@
16 16
17;;; Code: 17;;; Code:
18 18
19;; Let's use lexical binding by default, shall we?
20(setq-default lexical-binding t)
21
22;; For some reason, the above setting doesn't translate to the *scratch*
23;; buffer, where I try out packages.
24(advice-add 'setup :around
25 (defun acdw/setup-lexical-advice (orig-fun &rest args)
26 "Wrap `setup' in a `lexical-binding' form."
27 (let ((lexical-binding t))
28 (apply orig-fun args))))
29
30 19
31;;; Necessary packages 20;;; Necessary packages
32 21
@@ -843,6 +832,11 @@ if ripgrep is installed, otherwise `consult-grep'."
843 eval-expression-print-level nil 832 eval-expression-print-level nil
844 lisp-indent-function #'lisp-indent-function) 833 lisp-indent-function #'lisp-indent-function)
845 834
835 (defun acdw/enforce-lexical-binding ()
836 (setq lexical-binding t))
837
838 (add-hook 'emacs-lisp-mode-hook #'acdw/enforce-lexical-binding)
839
846 (defun acdw/eval-region-or-buffer () 840 (defun acdw/eval-region-or-buffer ()
847 (interactive) 841 (interactive)
848 (if (region-active-p) 842 (if (region-active-p)