Go language
Go language
Has anyone spent some time experimenting with the Google Go Programming Language: http://golang.org/ ?
It recently officially went to version 1.
It recently officially went to version 1.
-
IdeasVacuum
- Always Here

- Posts: 6426
- Joined: Fri Oct 23, 2009 2:33 am
- Location: Wales, UK
- Contact:
Re: Go language
I haven't used it - my first reaction was, it's Google, let's wait and see if they continue it's development or dump it and move on to something else. Well, it looks as though they are actually producing an innovative language that is both easy to use and is as modern as more recent hardware. They still have much work to do but it looks like Go is here to stay.
IdeasVacuum
If it sounds simple, you have not grasped the complexity.
If it sounds simple, you have not grasped the complexity.
Re: Go language
I started looking at it a few days ago.
My first impression is that it has potential, gothread are performing like Erlang as long as your on a single computer and the channels are nice & easy to use. But, after writing a little test codes I start to really miss a working IDE that keeps track of syntax and the names of any procedure.
Compiling if fast and the result is not too bloated (accepting all the framework that are included). "Hello World" ends up like 1.2 Mb, but more complex programs seems to grows slower.
It has clear potential. But version 1 is nothing I would try to use more serious today, the setup I ended up with (Notepad++ with go's included syntax highlighting & compiling from the console) feels too much like being back hacking ANSI C-code in 1988...
Give me a reasonable GUI and I may come back, but for now its not for me.
So for the language itself, a strong 4/5
The complete package, maybe 2/5
My first impression is that it has potential, gothread are performing like Erlang as long as your on a single computer and the channels are nice & easy to use. But, after writing a little test codes I start to really miss a working IDE that keeps track of syntax and the names of any procedure.
Compiling if fast and the result is not too bloated (accepting all the framework that are included). "Hello World" ends up like 1.2 Mb, but more complex programs seems to grows slower.
It has clear potential. But version 1 is nothing I would try to use more serious today, the setup I ended up with (Notepad++ with go's included syntax highlighting & compiling from the console) feels too much like being back hacking ANSI C-code in 1988...
Give me a reasonable GUI and I may come back, but for now its not for me.
So for the language itself, a strong 4/5
The complete package, maybe 2/5
The best preparation for tomorrow is doing your best today.
Re: Go language
auto completion for vim, emacs and others : https://github.com/nsf/gocode
sublime text plugin (rely on gocode) : https://github.com/DisposaBoy/GoSublime
eclipse plugin : http://code.google.com/p/goclipse/
golang ide : http://code.google.com/p/golangide/
sublime text plugin (rely on gocode) : https://github.com/DisposaBoy/GoSublime
eclipse plugin : http://code.google.com/p/goclipse/
golang ide : http://code.google.com/p/golangide/
Re: Go language
I tried go but the lack of parenthesis put me off the syntax. I prefer the D language instead.USCode wrote:Has anyone spent some time experimenting with the Google Go Programming Language: http://golang.org/ ?
It recently officially went to version 1.
C provides the infinitely-abusable goto statement, and labels to branch to. Formally, the goto is never necessary, and in practice it is almost always easy to write code without it. We have not used goto in this book. -- K&R (2nd Ed.) : Page 65
Re: Go language
You can add parenthesis in IFs and FORs if you want to.Blood wrote:I tried go but the lack of parenthesis put me off the syntax.
(if this is what you are talking about...)
Actually you can add them every where you want...
I just went the other way around.Blood wrote:I prefer the D language instead.
Started looking into D years back and wrote ~50K of useful code and now I get somewhat annoyed:
After all these years:
GDC is unusable on Windows - DMD compiles my program just fine but GDC does not (newest version)
There will be no DMD for 64 bit Windows. So on 64 bit Windows GDC it is.
The language seems to shift and loose the easy syntax that D v1 had.
Sure they tried to fix things, but every time I look at some D v2 code it get's more complicated and weird.
(especially with complicated code, duh...)
Maybe the major problem of D is that it tries to be all things to all people - and with that it satisfies no one completely.
(except the people involved in the compiler/language)
Go seems to go the other way and tries to simplify the needed syntax - especially for complicated code.
The compile time is very, very fast compared to C++ or GDC (DMD is acceptable but still way slower than Go) .
It is already used inside Google on different projects which tells you something about the state of the compiler.
Compiling is easy just do:
Code: Select all
go build hello.go
The smallest possible hello world program is ~200kb (64 bit) if the internal printf is used.
With fmt.Printf the size grows to ~1.2mb (64 bit) because of the runtime.
But even with D a program with ~50K of code compiles with DMD now to ~500kb (32 bit) and it used to be ~1mb a few versions back (depending on the library functions used)
Last weekend I bought a e-book as PDF (The Way To Go - 629 pages -$3.99) about Go and started reading it whenever I can.
BTW: Go is BSD licensed and the "Google" name is not in the code - they left it out.
Also (as with D) more and more people from the outside are involved in it.
Maybe when I'm done with the book I will find out that Go doesn't suit me, but for now I'm pleased.
Ask me again when I wrote ~50K of useful code in Go
I am to provide the public with beneficial shocks.
Alfred Hitshock
Re: Go language
Some folks here have touched on one of the key reasons why PB appeals to me and why Go is interesting: quick compilation.
You can write some code and test it quickly without waiting for a lengthy complile-link cycle.
I guess the key problem here with Go for many folks is the lack of an integrated IDE for Go.
How about the standard go package library? How does it compare to PB's?
You can write some code and test it quickly without waiting for a lengthy complile-link cycle.
I guess the key problem here with Go for many folks is the lack of an integrated IDE for Go.
How about the standard go package library? How does it compare to PB's?
Re: Go language
you should try smalltalk, python or common lisp. with those languages you can code and modify your program while running.USCode wrote:Some folks here have touched on one of the key reasons why PB appeals to me and why Go is interesting: quick compilation.
You can write some code and test it quickly without waiting for a lengthy complile-link cycle.
I guess the key problem here with Go for many folks is the lack of an integrated IDE for Go.
How about the standard go package library? How does it compare to PB's?
http://en.wikipedia.org/wiki/Read%E2%80 ... print_loop
Re: Go language
And VB6 also...
This is a powerful feature in rapid prototyping.
Of course, a fast compiler is preferred for end use.
This is a powerful feature in rapid prototyping.
Of course, a fast compiler is preferred for end use.
The nice thing about standards is there are so many to choose from. ~ Andrew Tanenbaum
Re: Go language
I've looked at those in the past, no thanks. I didn't explain myself very well, my point was you get a compiled native executable with good speed and no interpreter required.xorc1zt wrote:you should try smalltalk, python or common lisp. with those languages you can code and modify your program while running.
http://en.wikipedia.org/wiki/Read%E2%80 ... print_loop
With the rapid compilation you can recompile your app and have the executable up and running for testing as quickly as those other systems take to start the interpreter.
Re: Go language
haskell and common lisp can produce native executable, you just need to start the repl one time and when you have done your work you compile the code. haskell is faster than go when clisp from steelbank is a little slower.
http://www.sbcl.org/
http://www.haskell.org/haskellwiki/Haskell
http://www.sbcl.org/
http://www.haskell.org/haskellwiki/Haskell
Re: Go language
The Go standard library has gotten to be pretty comprehensive:
http://golang.org/pkg/
http://golang.org/pkg/

