about summary refs log tree commit diff stats
path: root/lisp/acdw-lisp.el
blob: 92fe62e8da88591190c6c7426ac7394c48e408c1 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
;;; acdw-lisp.el -*- lexical-binding: t; coding: utf-8-unix -*-
;;
;; Extras for Lisp modes.

(defun acdw/eval-region-or-buffer ()
  (interactive)
  (if (region-active-p)
      (let ((begin (region-beginning))
            (end (region-end)))
        (with-message (format "Evaluating %S -> %S" begin end)
          (eval-region begin end)))
    (with-message "Evaluating buffer"
      (eval-buffer))))

(provide 'acdw-lisp)
;;; acdw-lisp.el ends here