[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: The new Google "Go" language - with n=0..N buffered blocking channels



On Thu, Nov 12, 2009 at 12:37 AM, Rick Beton <rick.beton@xxxxxxxxx> wrote:
> 2009/11/11 Teig, Oyvind UTCFS <Oyvind.Teig@xxxxxxxxxxxxxxxx>
>>
>>
>> http://developers.slashdot.org/story/09/11/11/0210212/Go-Googles-New-Open-Source-Programming-Language?art_pos=1
>>
>> http://golang.org/
>
> Interesting.  A new version of C which is a big improvement on C, albeit
> still with dependence on reference (/pointer) aliasing.
>
> http://en.wikipedia.org/wiki/Go_%28programming_language%29 :
>>
>> The syntax of Go is close to that of C except for the type declarations;
>> other syntactical differences are the missing brackets around for and if
>> expressions. The language supports garbage collection. The concurrency model
>> of Go is modeled after Tony Hoare's CSP, like previous concurrent
>> programming languages such as occam or Limbo,[1] but also has features of
>> the Pi calculus such as channel passing.
>>
>> Features not present in Go include exception handling, type inheritance,
>> generic programming, assert and method overriding.[1] Of those, Google are
>> still having an open mind about generic programming, while assertions are
>> argued against in the language FAQ, and the choice of no type inheritance
>> defended. Unlike Java, maps (a.k.a. hashes or dictionaries) are built-in
>> like strings.
>
> The concurrency introduction is here:
> http://golang.org/doc/go_tutorial.html#tmp_331

Out of curiosity I threw together a quick commstime.go benchmark, and
my initial impression is that its roughly 4 times slower than KRoC for
the same.  I'm doing quite a bit of playing with it now, and the most
peculiar thing I'm running into is the way channels get closed.

- Jim