编译Go编程语言有多难?

时间:2010-01-03 13:27:06

标签: process compilation go

基本上标题是什么:编译普通go *文件的过程是什么?将它放在编译器上并执行结果?


*注意:OP在回滚之前编辑了将“go”替换为“C”的问题。所以有些答案是没有意义的。

1 个答案:

答案 0 :(得分:3)

您是否在http://golang.org/doc/go_tutorial.html

看了一下Go教程
    Here's how to compile and run our program. With 6g, say,

        $ 6g helloworld.go  # compile; object goes into helloworld.6
        $ 6l helloworld.6   # link; output goes into 6.out
        $ 6.out
        Hello, world; or Καλημέρα κόσμε; or こんにちは 世界
        $

    With gccgo it looks a little more traditional.

        $ gccgo helloworld.go
        $ a.out
        Hello, world; or Καλημέρα κόσμε; or こんにちは 世界