Strange escape sequences in Emacs elisp backtrace

When I use toggle-debug-on-error and look at the backtrace generated in the Backtrace buffer, there are many screen keys that don’t seem like they should be there, for example:

Debugger entered--Lisp error: (invalid-read-syntax "#")
  read(#<buffer emacs-config.org>)
  eval-defun-2()
  #[257 "\211\203
\303\304!\210\305?!\207   \204\306 \207\307\310!\311\211\306 \262\n\262)=\204+\207" [edebug-all-defs eval-expression-debug-on-error debug-on-error require edebug eval-defun eval-defun-2 make-symbol "t" nil] 6 2405975 "P"](nil)
  ad-Advice-eval-defun(#[257 "\211\203
\303\304!\210\305?!\207   \204\306 \207\307\310!\311\211\306 \262\n\262)=\204+\207" [edebug-all-defs eval-expression-debug-on-error debug-on-error require edebug eval-defun eval-defun-2 make-symbol "t" nil] 6 2405975 "P"] nil)

What is it, and how can I remove it or convert it into something useful?

+3
source share
2 answers

This is byte-compiled code. See elisp-manual Section "16.2 Byte Compilation Functions".

The actual problem is that you are trying to read-eval org-file (perhaps beyond load-file). This does not work. What you can do in the buffer in org-mode is org-babel-execute-buffer. Document for this function:

org-babel-execute-buffer is an interactive autoloaded compiled Lisp
function in `ob-core.el'.

It is bound to C-c C-v b, C-c C-v C-b.

(org-babel-execute-buffer &optional ARG)

Execute source code blocks in a buffer.
Call `org-babel-execute-src-block' on every source block in
the current buffer.
+1
source

-

(defun foo (x) "Double a number" (+ x x))

(byte-compile 'foo) =>
#[(x) "\211\\\207" [x] 2 "Double a number"]

ie

#[
  (x)                 ; arguments
  "\211\\\207"        ; byte-code
  [x]                 ; constants
  2                   ; stacksize
  "Double a number"   ; docstring
  ]

-

(disassemble (byte-compile 'foo)) =>

byte code:
  doc:  double a number
  args: (x)
0       varref    x
1       dup       
2       plus      
3       return    

:

, , . , - .

0

All Articles