Workaround a bug for octave-mode of Emacs 25.2.50 under MS-Windows
When I switched to the master branch of Emacs, I found that octave-mode doesn’t work correctly. The run-octave will result in the crash of “octave-gui.exe”, even without the configuration file. Afer hours of digging, I think the problem is related to the default-directory. That is, no matter what the PATH is, only when the default-directory being the directory of octave program can make it work. This may relate to the octave, but in Emacs 24.5 run-octave works correctly. Strang enough. I can workaround the problem by temporarily setting the default-directory. The code looks like:
1 | (let ((default-directory (file-name-directory |
MS-Windows下变通解决Emacs 25.2.50的octave-mode的bug
当换到master分支后,我发现octave-mode工作不正常了,现象是“octave-gui.exe”崩溃。我捉摸了好长时间,觉得问题出在default-directory取值的问题,不论PATH怎么设置,只有default-directory是octave.exe所在目录时才不会崩溃。这似乎和octave有关系,但Emacs 24.5是正常的,很奇怪。要完全解决这个问题我的功力恐怕不够,只要暂时设置default-directory就好了。代码就像下面的样子:
1 | (let ((default-directory (file-name-directory |
或者您可以把评论发在别处,添加指向本页的连接,然后把网址告诉我:
本文标题:Workaround a bug for octave-mode of Emacs 25.2.50 under MS-Windows
文章作者:Chris
发布时间:2016-09-24
最后更新:2022-03-23
原始链接:https://chriszheng.science/2016/09/24/Workaround-a-bug-for-octave-mode-of-Emacs-25-2-50/
版权声明:本博客所有文章除特别声明外,均采用 CC BY 4.0 许可协议。转载请注明出处!
分享