Support prelude/time
Write macro that wraps Elisp's builtin `benchmark` function. I'm doing this because `prelude/time` more closely resembles the API that I would expect.
This commit is contained in:
parent
df4eed20f4
commit
d45debc8e5
1 changed files with 4 additions and 0 deletions
|
@ -133,5 +133,9 @@ This is a wrapper around `start-process' that has an API that resembles
|
|||
(f-exists? file)
|
||||
nil)))
|
||||
|
||||
(defmacro prelude/time (x)
|
||||
"Print the time it takes to evaluate X."
|
||||
`(benchmark 1 ',x))
|
||||
|
||||
(provide 'prelude)
|
||||
;;; prelude.el ends here
|
||||
|
|
Loading…
Reference in a new issue