News for hackers. Stuff that matters.
Re:Go's Declaration Syntax (2010) by adrianlmm on Sunday November 23, 2014 @10:42AM (#8649015)
One of the main reasons is because Go syntax is designed for fast compilation.
Re:Go's Declaration Syntax (2010) by raverbashing on Sunday November 23, 2014 @11:11AM (#8649084)
I'd like to see the impact of different grammars in compilation time, which I suspect are small.

C++ compilation is not slow because of the grammar, but because of things like multiple includes

Re:Go's Declaration Syntax (2010) by vidarh on Sunday November 23, 2014 @12:17PM (#8649234)
I've yet to see any evidence that Go is all that fast to compile, but whether it is or not there's simply no way that the syntax will be what makes a difference vs C.

Compilers like GCC are "slow" because they do a lot of work. To see a good demonstration of how fast C compilation can be, consider Bellards TCCBOOT [1] which boots into a version of TCC that then compiles a Linux kernel and executes it - the compilation took a reported 10 seconds on a 2.4GHz Pentium 4 in 2004. When testing against the then-current gcc 3.2 with -O0, TinyCC was about 9 times faster than GCC.

There are certainly things about C that makes fast compilation tricky, but it's not the syntax (abusing a text based pre-processor instead of having a proper module system being suspect #1)

Even so, last time I looked, GCC stood up fairly well agains the Go.

[1] http://bellard.org/tcc/

Re:Go's Declaration Syntax (2010) by WalterBright on Sunday November 23, 2014 @01:51PM (#8649500)
The declaration syntax detail has nothing to do with compilation speed.