mirror of
https://github.com/vale981/emacs-jupyter
synced 2025-03-04 15:41:37 -05:00
Don't attempt to byte-compile
a symbol whose function value is a subr
`(byte-compile #'cons)` will return `t` which is not a function. Passing in the `subr` to `byte-compile` will just return the `subr` so everything works out OK. This is an attempt at fixing issues like nnicandro/emacs-zmq#32.
This commit is contained in:
parent
85f6ff84ed
commit
eebeef1293
1 changed files with 5 additions and 1 deletions
|
@ -339,7 +339,11 @@ nothing."
|
|||
;; Initialize any callbacks that were added before the ioloop was
|
||||
;; started
|
||||
(setq jupyter-ioloop-pre-hook
|
||||
(mapcar (lambda (f) (unless (byte-code-function-p f) (byte-compile f)))
|
||||
(mapcar (lambda (f)
|
||||
(when (symbolp f)
|
||||
(setq f (symbol-function f)))
|
||||
(unless (byte-code-function-p f)
|
||||
(byte-compile f)))
|
||||
(append jupyter-ioloop-pre-hook
|
||||
(quote ,(mapcar #'macroexpand-all
|
||||
(oref ioloop callbacks))))))
|
||||
|
|
Loading…
Add table
Reference in a new issue