4 ms·
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. Bu
by enneff 15y ago
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 http://blog.golang.org/2010/07/gos-declaration-syntax.html
- TillE 15y agoThe 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.
- enneff 15y agoThere are good reasons. See the blog post I linked to.
- rdtsc 15y agoI guess it is something like the Valley of The Uncanny for languages. Yes, it looks deceivingly similar to C++, C & Java, but is not any of those. When your eyes see the syntax, your brain expects the functionality to be the same. However Go does introduce fairly radical new paradigms (goroutines, type inference...) that really upsets that initial feeling of familiarity. I (unlike the majority) like Erlang's completely strange and radical syntax. When I see, it tells me that "there is something completely new happening here, don't expect this to be C++ plus processes" or something like that.
- hvs 15y agoI agree except for the whole ";" "," "." line endings issue. When I can't copy and paste to move lines around without "fiddling" with the line endings, I get angry.
- deleted 15y ago[deleted]
- kragen 15y agoI think the solution is to treat those as line beginnings rather than endings: http://news.ycombinator.com/item?id=2389715 http://news.ycombinator.com/item?id=2389715
- extension 15y agoIt seems some programmers just will not accept new syntax at all. I think it's a waste of time trying to please these people and, contrary to popular belief, you don't need their blessing to make a successful new language. Coffeescript is an example that supports this.
- breckinloggins 15y agoIt's a valid point, but it paints with too broad of a brush. For example, I have enthusiastically moved from JavaScript to CoffeeScript, in part because I love the syntax. While I know there are programmers who act just like you described, my complaint is with Go's syntax specifically.