在org文档中任何一处敲Enter键之后,
都会报错:
Debugger entered--Lisp error: (wrong-type-argument wholenump -98)
make-list(-98 nil)
lisp-indent-initial-state()
indent-sexp()
paredit-newline()
funcall-interactively(paredit-newline)
call-interactively(paredit-newline nil nil)
command-execute(paredit-newline)
收到的解决方案, 过了几天就失效
org mode - Debugger entered–Lisp error: (wrong-type-argument wholenump -47) when press ‘enter’ in orgorg - Emacs Stack Exchange
M-x paredit-mode, 提示unmatched bracket or quote.
是这个吗?
Enter后还报错.
貌似一个问题:
Org Mode 为什么用 ParEdit 的命令
1 个赞
cireu
6
另外个人推荐用smartparens,对org-mode有加成
(use-package smartparens
:defer 1
:preface
(defvar cm/enable-sp-in-minibuffer-commands
'(eval-expression eldoc-eval-expression)
"Enable `smartparens' in some minibuffer-based commnads")
:hook (prog-mode . turn-on-smartparens-strict-mode)
:config
(require 'smartparens-config)
(smartparens-global-mode 1)
(defun cm/enable-sp-in-minibuffer ()
"Enable `smartparens' in minibuffer sometimes"
(when (memq this-command cm/enable-sp-in-minibuffer-commands)
(smartparens-mode)))
(add-hook 'minibuffer-setup-hook #'cm/enable-sp-in-minibuffer)
(sp-local-pair 'minibuffer-inactive-mode "'" nil :actions nil)
;; Fix overlay problem with yasnippet
(with-eval-after-load 'yasnippet
(advice-add #'yas-expand :before #'sp-remove-active-pair-overlay)))
1 个赞
感谢, 试试…
P.S. function:use-package 需要从melpa中安装.