Emacs以haskell-load-file调用挂在haskell-mode中 [英] Emacs hangs in haskell-mode with inferior-haskell-load-file call

查看:247
本文介绍了Emacs以haskell-load-file调用挂在haskell-mode中的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

在Haskell文件中,我使用 Cc Cl 来运行命令 inferior-haskell-load-file 目的是将当前文件加载到GHCI解释器中,但Emacs只是挂起,直到我点击 Cg 。任何人都知道我可以如何让这个工作?

When in a Haskell file, I use C-c C-l to run the command inferior-haskell-load-file which is intended to load the current file into the GHCI interpreter but Emacs just hangs until I hit C-g. Anyone know how I can get this to work?

2011-08-的GNU Emacs 23.3.1(x86_64-pc-linux-gnu,GTK +版本2.24.5) 14在allspice上,由Debian修改

GNU Emacs 23.3.1 (x86_64-pc-linux-gnu, GTK+ Version 2.24.5) of 2011-08-14 on allspice, modified by Debian

使用haskell-mode版本v2.7.0

Using haskell-mode version v2.7.0

推荐答案

inferior-haskell-mode根据预期的ghci提示进行一些解析。因此,如果您在 .ghci 文件中更改提示,则无法检测到它。

inferior-haskell-mode does some parsing based upon the expected ghci prompt. As such, if you change the prompt in a .ghci file, then it can't detect it.

有关更多信息,请参阅 haskell-ghci.el comint-prompt-regexp 值来确定提示符是什么。

For more information, see where haskell-ghci.el sets the comint-prompt-regexp value to determine what a prompt is.

;; GHCi prompt should be of the form `ModuleName> '.
(setq comint-prompt-regexp
      "^\\*?[[:upper:]][\\._[:alnum:]]*\\( \\*?[[:upper:]][\\._[:alnum:]]*\\)*> ")

如果您想保留 .ghci 文件中的设置,则可以自定义此设置。

If you want to keep the setting in your .ghci file, then it may be possible to customise this settings.

这篇关于Emacs以haskell-load-file调用挂在haskell-mode中的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆