简体   繁体   English

Erlang编译错误

[英]Erlang compile error

Windows XP, Erlang R13B02 (erts-5.7.3) Windows XP,Erlang R13B02(erts-5.7.3)

Today werl desn't want compile any erlang file 今天werl不想编译任何erlang文件

c(binm). C(binm)。 ** exception error: undefined function compile:file/2 in function c:c/2 **异常错误:未定义函数compile:函数c:c / 2中的file / 2

Yesterday all work. 昨天全部工作。

PS install R14B03, can't compile again PS安装R14B03,无法再次编译

That is a very odd error. 这是一个非常奇怪的错误。 Have you by accident deleted the compile.beam file from your OTP installation? 您是否偶然从OTP安装中删除了compile.beam文件? A re-installation of R13B02 might solve it, if you don't want to change the OTP version. 如果您不想更改OTP版本,重新安装R13B02可能会解决此问题。

But if you don't need to use R13B02 for any particular reason, I recommend taking the opportunity to uninstall it and install the latest version (R14B03) instead ( http://www.erlang.org/download.html ). 但如果您因任何特殊原因不需要使用R13B02,我建议您借此机会将其卸载并安装最新版本(R14B03)( http://www.erlang.org/download.html )。 There have been many improvements, in particular regarding type specifications. 已经有许多改进,特别是关于类型规格。

What does io:format("~p~n", [code:get_path()]). 什么是io:format("~p~n", [code:get_path()]). print? 打印? It should contain a directory like somepath/lib/compiler-4.7.2/ebin . 它应该包含一个像somepath/lib/compiler-4.7.2/ebin这样的目录。 Check that that directory actually exists, and that it contains the file compile.beam . 检查该目录是否确实存在,并且它包含文件compile.beam

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM