branch: externals/el-job commit 6fa04dae03f577a212ac5cd2c69e3fb4f6bf3d07 Author: Martin Edström <meedst...@runbox.eu> Commit: Martin Edström <meedst...@runbox.eu>
Fix some cases of "void function" Case study: indexed-org-parser.el has a stub definition of `org-mode`, so when el-job--locate-lib-in-load-history looks for the feature `indexed-org-parser`, it sometimes thinks the feature comes from org.el, because a definition for `org-mode` is also found there. --- el-job.el | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/el-job.el b/el-job.el index f48c219c45..de4fbde371 100644 --- a/el-job.el +++ b/el-job.el @@ -107,7 +107,11 @@ an .eln anyway, without your having to recompile on save." when (and (consp elem) (eq 'defun (car elem)) (symbolp (cdr elem)) - (subrp (symbol-function (cdr elem)))) + (subrp (symbol-function (cdr elem))) + ;; Extra safety (sometimes files contain a patch + ;; overriding some other file's definition) + (string-prefix-p (symbol-name feature) + (symbol-name (cdr elem)))) return (native-comp-unit-file (subr-native-comp-unit (symbol-function (cdr elem))))))