mirror of
git://git.sv.gnu.org/emacs.git
synced 2025-12-06 06:20:55 -08:00
* lisp/emacs-lisp/comp.el (comp-lookup-eln): Add new function.
This commit is contained in:
parent
5aa42f686c
commit
6351953dcd
1 changed files with 14 additions and 0 deletions
|
|
@ -4099,6 +4099,20 @@ bytecode definition was not changed in the meantime)."
|
|||
|
||||
;;; Compiler entry points.
|
||||
|
||||
(defun comp-lookup-eln (filename)
|
||||
"Given a Lisp source FILENAME return the corresponding .eln file if found.
|
||||
Search happens in `comp-eln-load-path'."
|
||||
(cl-loop
|
||||
with eln-filename = (comp-el-to-eln-rel-filename filename)
|
||||
for dir in comp-eln-load-path
|
||||
for f = (expand-file-name eln-filename
|
||||
(expand-file-name comp-native-version-dir
|
||||
(expand-file-name
|
||||
dir
|
||||
invocation-directory)))
|
||||
when (file-exists-p f)
|
||||
do (cl-return f)))
|
||||
|
||||
;;;###autoload
|
||||
(defun native-compile (function-or-file &optional output)
|
||||
"Compile FUNCTION-OR-FILE into native code.
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue