在emacs ocaml错误消息中显示除字符外的行号

在emacs ocaml错误消息中显示除字符外的行号,emacs,ocaml,tuareg,Emacs,Ocaml,Tuareg,现在我处于Emacs tuareg模式,我收到了这个错误消息 * * * * * * * * * * * Characters 2686-2820: 但不可能找到发生这种情况的地方 这是我的.emacs文件- (add-to-list 'load-path "~/tuareg-caml-mode") (add-to-list 'load-path "~/tuareg-2.0.4") (setq auto-mode

现在我处于Emacs tuareg模式,我收到了这个错误消息

             * * *             * * * * * *       * *           Characters 2686-2820:
但不可能找到发生这种情况的地方

这是我的.emacs文件-

(add-to-list 'load-path "~/tuareg-caml-mode")
(add-to-list 'load-path "~/tuareg-2.0.4")
(setq auto-mode-alist (cons '("\\.ml\\w?" . tuareg-mode) auto-mode-alist))
(autoload 'tuareg-mode "tuareg" "Major mode for editing Caml code" t)
(autoload 'camldebug "camldebug" "Run the Caml debugger" t)
(custom-set-variables
 ;; custom-set-variables was added by Custom.
 ;; If you edit it by hand, you could mess it up, so be careful.
 ;; Your init file should contain only one such instance.
 ;; If there is more than one, they won't work right.
 )
(custom-set-faces
 ;; custom-set-faces was added by Custom.
 ;; If you edit it by hand, you could mess it up, so be careful.
 ;; Your init file should contain only one such instance.
 ;; If there is more than one, they won't work right.
 )
(require 'linum)             
(global-linum-mode 1)

我想知道同样的事情,并怀疑一定有某种方便的解决方案,为我们在那里已经。首先,我发现:


其中包含图阿雷格模式的所有相关捷径。第二,从那个备忘单中,顶层的“ctrl-c”(control-c撇号)会直接带您找到手头的错误。(对我来说,当我将一个函数输入顶层而不是一个完整的缓冲区时,这似乎效果更好)

记录在案:
M-:(goto char 2686)
就可以了。但我理解这带来的不便。你是如何得到这个错误的?我通常只是简单地将定义复制到顶层来测试它,此时它将在顶层打印整个错误消息。@wvxvw给出了如何转到该缓冲区位置的答案。较短的版本是
M-g c 2686