我正在用 Ocaml 编写编译器。当我make
在终端中编译和测试它时,回溯效果很好,例如:
export OCAMLRUNPARAM=b
./Simpler-Basic test.sib
Fatal error: exception Match_failure("interp.ml", 45, 21)
Called from file "interp.ml", line 97, characters 72-86
Called from file "list.ml", line 74, characters 24-34
Called from file "interp.ml", line 108, characters 9-35
Called from file "main.ml", line 54, characters 4-17
make: *** [all] Error 2
但是当我在我的 Emacs 中编译并测试它时Meta-x compile
,make
它不会在缓冲区中显示回溯部分:
make
export OCAMLRUNPARAM=b
./Simpler-Basic test.sib
Fatal error: exception Match_failure("interp.ml", 45, 21)
make: *** [all] Error 2
Compilation exited abnormally with code 2 at Sat Jun 18 19:03:04
.emacs
我从朋友那里复制了我要做的一部分回溯:http: //paste.ubuntu.com/628838/
谁能告诉我如何修改我的.emacs
,以便它在终端中显示回溯?非常感谢你