Add docstrings to FILE! & DIR! macros
This commit is contained in:
parent
1c3183b298
commit
fe6afa19a3
1 changed files with 2 additions and 2 deletions
|
@ -189,14 +189,14 @@ MATCH is a string regexp. Only entries that match it will be included."
|
||||||
;;
|
;;
|
||||||
|
|
||||||
(defmacro FILE! ()
|
(defmacro FILE! ()
|
||||||
"TODO"
|
"Return the emacs lisp file this macro is called from."
|
||||||
`(cond ((bound-and-true-p byte-compile-current-file))
|
`(cond ((bound-and-true-p byte-compile-current-file))
|
||||||
((stringp (car-safe current-load-list)) (car current-load-list))
|
((stringp (car-safe current-load-list)) (car current-load-list))
|
||||||
(load-file-name)
|
(load-file-name)
|
||||||
(buffer-file-name)))
|
(buffer-file-name)))
|
||||||
|
|
||||||
(defmacro DIR! ()
|
(defmacro DIR! ()
|
||||||
"TODO"
|
"Returns the directory of the emacs lisp file this macro is called from."
|
||||||
`(let ((file (FILE!)))
|
`(let ((file (FILE!)))
|
||||||
(and file (file-name-directory file))))
|
(and file (file-name-directory file))))
|
||||||
|
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue