1

In org-mode, I have the following:

#+BEGIN_SRC emacs-lisp :results scalar
(setq no-byte-compile t)
(defun f ())
(defun g ())
(add-function :before (symbol-function 'f) 'g)
(symbol-function 'f)
#+END_SRC

#+RESULTS:
: #[128 "\300\301\"\210\300\302\"\207" [apply g (lambda nil nil) nil] 4 nil]

I wanted to see what adding advice did to the function. Why is byte compilation happening, despite no-byte-compile being t? How do I prevent byte compilation in this case?

1

Why is byte compilation happening...?

Strictly speaking no byte-compilation is happening, from the looks of it.

advice--make-1 actually generates byte code directly via make-byte-code.

This is obviously a low-level approach, and offhand I'm surprised to see that going on outside of compilation; but perhaps it's more common than I imagine -- I have little knowledge in this area.

| improve this answer | |

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.