Go Rocks - How Can We Avoid Something This Bad In The Future?
1–10 of 68 posts
Re: Go Rocks - How Can We Avoid Something This Bad In The Future?
#2Re: Go Rocks - How Can We Avoid Something This Bad In The Future?
#3Re: Go Rocks - How Can We Avoid Something This Bad In The Future?
#4I tend to write erlang or c++ mostly for my day job. I do really wish the designers had a bit more erlang experience. Just a touch. Just enough so that I had a way to propagate the death of a goroutine through a bunch of other goroutines without building all of that manually.
For example, code I wrote today:
That infinite loop is really infinite. If the goroutine feeding the channel dies (e.g. if the connection is dropped), this thing will keep reading on the channel. In erlango, I'd do something like "go_link client.Feed(ch)" and the right thing would happen. Here, I really need to spin up a second channel to send out the death spurt, select across the channels in my loop and send my death message with defer.
defer is awesome, and I wish every language had it (C++ has something that looks like it if you write enough code and squint hard enough). Still, I've got a lot of code like the above and I imagine it's not an uncommon thing.
Every language has something that just feels unjustifiably wrong with it, though. go certainly isn't one I'd be pained to use if I had to every day.
(Edit: couldn't figure out code formatting, tossed it over to pastebin)
Re: Go Rocks - How Can We Avoid Something This Bad In The Future?
#5Can anyone who shares my opinion chime in on what things they think cause the syntax to suffer aesthetically?
Re: Go Rocks - How Can We Avoid Something This Bad In The Future?
#6I still think the major stumbling block for Go is the syntax. I can't put my finger on it, but from the first time I saw it I thought it looked wrong. Can anyone who shares my opinion chime in on what things they think cause the syntax to suffer aesthetically?
Re: Go Rocks - How Can We Avoid Something This Bad In The Future?
#7I wrote a bunch of go code this morning. It's definitely got a few really neat ideas in it. I tend to write erlang or c++ mostly for my day job. I do really wish the designers had a bit more erlang experience. Just a touch. Just enough so that I had a way to propagate the death of a goroutine through a bunch of other goroutines without building all of that manually. For example, code I wrote today: http://pastebin.co…
Re: Go Rocks - How Can We Avoid Something This Bad In The Future?
#8I still think the major stumbling block for Go is the syntax. I can't put my finger on it, but from the first time I saw it I thought it looked wrong. Can anyone who shares my opinion chime in on what things they think cause the syntax to suffer aesthetically?
Try it for two days and you'll change your mind.
Also, see: http://blog.golang.org/2010/07/gos-declaration-syntax.html
Re: Go Rocks - How Can We Avoid Something This Bad In The Future?
#9I still think the major stumbling block for Go is the syntax. I can't put my finger on it, but from the first time I saw it I thought it looked wrong. Can anyone who shares my opinion chime in on what things they think cause the syntax to suffer aesthetically?
I'm amazed by this particular criticism of Go. Compared to many modern languages (Erlang or Ruby, for example), Go's syntax is barely different to Java or C. But I think it's better than either of those (It's certainly more regular). Try it for two days and you'll change your mind. Also, see: http://blog.golang.org/2010/07/gos-declaration-syntax.html
Go is the only language I've ever tried for a while and been really put off by the syntax. I can't quite articulate why either. It's not...pretty. I write quite a lot of C++ and Python, so theoretically I should be a pretty good fit for Go. But it doesn't click with me.
Re: Go Rocks - How Can We Avoid Something This Bad In The Future?
#10Earlier quoted context omitted.
I'm amazed by this particular criticism of Go. Compared to many modern languages (Erlang or Ruby, for example), Go's syntax is barely different to Java or C. But I think it's better than either of those (It's certainly more regular). Try it for two days and you'll change your mind. Also, see: http://blog.golang.org/2010/07/gos-declaration-syntax.html
The trouble is that it borrows a lot from C and then subtly changes it for no discernible reason. This is especially true with variable declaration. Go is the only language I've ever tried for a while and been really put off by the syntax. I can't quite articulate why either. It's not...pretty. I write quite a lot of C++ and Python, so theoretically I should be a pretty good fit for Go. But it doesn't click with me.