我按照文档进行了编译,nim compileToC helloworld.nim
但它只是吐出了一个可执行文件。如何查看中间 C 表示?
问问题
5972 次
3 回答
13
nim -c -d:release c helloworld.nim
just creates the C files in nimcache
, without compiling and linking them. -d:release
makes the code easier to read.
于 2015-04-30T08:27:31.190 回答
12
2019 年更新 (Nim 0.19.2)
默认 nimcache 目录已从当前工作目录更改为:
$HOME/.cache/nim/<project_name>
适用于 Linux 和 MacOS$HOME/nimcache/<project_name>
适用于 Windows
有关详细信息,请参阅相关的nim 编译器文档文章。
于 2019-02-01T04:26:37.557 回答
3
已解决:当您编译 nim 程序时nimcache
,会在包含 c 代码的同一目录中自动生成一个目录。
于 2015-04-30T02:35:15.217 回答