File: init-tryout.el

package info (click to toggle)
lua-mode 20151025-3
  • links: PTS, VCS
  • area: main
  • in suites: buster, sid
  • size: 268 kB
  • sloc: lisp: 2,534; makefile: 33
file content (13 lines) | stat: -rw-r--r-- 447 bytes parent folder | download | duplicates (2)
1
2
3
4
5
6
7
8
9
10
11
12
13
(load-file "lua-mode.el")

(defmacro add-trace-for (fn)
  (let ((trace-fn-name (intern (concat "trace--" (symbol-name fn)))))
    `(progn
       (defun ,trace-fn-name (&rest args)
	 (message "%s was called with: %S" #',fn args))
       (add-function :before (symbol-function #',fn) #',trace-fn-name))))


;; (add-trace-for font-lock-fontify-region)
;; (add-trace-for font-lock-unfontify-region)
;; (add-trace-for lua--propertize-multiline-bounds)