Live data from Hacker News

Go is amazing, period.

poincare101.blogspot.com

191–200 of 241 posts

Re: Go is amazing, period.

#191
post #168
post #165

Earlier quoted context omitted.

A tip: if you have say 4 cores, then using 4000 threads will most likely be slow due to lots of context switches. I say most likely because it depends on the details, but it's a safe guess.

That is part of the problem; if you have 4 cores, your program should be using 4 OS-threads. Your programming language's runtime should take care of distributing your 4000 lightweight/green threads to the 4 actual threads. This is what e.g. Haskell does, and Go as well, I think.

> This is what e.g. Haskell does, and Go as well, I think.

This is what Erlang does by default, GHC >= 6.12 will do it when using `+RTS -N -RTS` and Go requires explicitly setting GOMAXPROCS, the runtime defaults to single-threaded (as far as I know, GOMAXPROCS still hasn't been retired) and there is no way to have it auto-detect the core count.

Re: Go is amazing, period.

#192
post #168

Earlier quoted context omitted.

That is part of the problem; if you have 4 cores, your program should be using 4 OS-threads. Your programming language's runtime should take care of distributing your 4000 lightweight/green threads to the 4 actual threads. This is what e.g. Haskell does, and Go as well, I think.

> This is what e.g. Haskell does, and Go as well, I think. This is what Erlang does by default, GHC >= 6.12 will do it when using `+RTS -N -RTS` and Go requires explicitly setting GOMAXPROCS, the runtime defaults to single-threaded (as far as I know, GOMAXPROCS still hasn't been retired) and there is no way to have it auto-detect the core count.

The current weekly release has (and Go v1 will have) runtime.NumCPU() so you can do runtime.GOMAXPROCS(runtime.NumCPU())

Re: Go is amazing, period.

#193
Inside a function, the := short assignment statement can be used in place of the short var declaration.

(Outside a function, every construct begins with a keyword and the := construct is not available.)

===

Why is that? I would find that frustrating and inconsistent.

Re: Go is amazing, period.

#194
post #101

Earlier quoted context omitted.

Did you try Haskell? Knowing Haskell makes reading about Go a very underwhelming experience.

Knowing any ML makes it pretty underwhelming.

Or even just any Lisp. http://briancarper.net/blog/497/im-turning-into-a-lisp-snob

Re: Go is amazing, period.

#195
Is the Author is 13 years old. When did he really start programming.? just wondering After 16 years of programming experience still not able to decide which language is best. At last Settled for C and Common Lisp. But still have Doubts. As per Personal Experience Both Language is more than enough for me.

Re: Go is amazing, period.

#196
post #128

Earlier quoted context omitted.

It's hard to expect a really detailed analysis from someone still in high school. On the other hand, it is good to see how the various languages look like from a fresh perspective of someone with relatively little preconceptions from years of using C/C++/Python/whatever. After all, if he has lots of problems with writing something in C++, but much less when writing it in Go, it probably means lots of us had at some p…

Please, ignore people's age, it makes people in high school much happier. From someone in highschool (or the UK equivalent), the age anonymity of the internet is one of it's greatest strengths. I think he'll still have to learn a fair few tricks to get around some features of Go. Things like type assertions, float32 vs float64, get ready for it lack of generics, and no distinction between stack and heap aren't common…

Wow, I had no idea that the OP was in high school. Kudos to him! His blog entry is close enough to other software dev blogs in quality that I think we can leave his age, identity and personality aside, and talk about what it takes to win people over to a new language.

Re: Go is amazing, period.

#197
post #155
post #147

Support for Unicode as a groundbreaking language feature? Closures (and first-class functions) as a major achievement? I don't want to sound smug, so I won't mention any languages I'm comparing to — but seriously, unless you've been living in Python-land, those things are nothing to write home about. I'm surprised this is getting so many upvotes. If I were to praise Go, I would concentrate on something innovative — c…

Closures and first-class functions aren't an achievement. Closures and first-class functions in a language low enough and fast enough level for systems programming? That's an achievement. Same for unicode. These aren't just features. These are features done fast .

Lisp has been having all these for five decades now and those features are done fast. http://shootout.alioth.debian.org/u32q/benchmark.php?test=al...

Re: Go is amazing, period.

#198

Earlier quoted context omitted.

I work in a place where people don't use spaces and don't use empty lines to separate logical groups of lines. It's a real pain for me who is a code format junkie as our code ends up being an ugly pack of unrelated crap that's really hard to read. It's Python code and I find it uglier than some fairly large C++ project I used to work on. Anyway, I wish there was a gofmt in Python because at least, I'd drop all hopes…

One time we worked on some code, and one of the developers had the same habit: "It works, so why do I need to format it?" We decided to make our build system run PEP over the code, resulting in a failure if PEP didn't pass. It annoyed the hell out of him, but we quickly got the formatting up to a better standard.

PEP8? http://www.python.org/dev/peps/pep-0008/

Re: Go is amazing, period.

#199
post #73

Earlier quoted context omitted.

I simply summarized your article. There is nothing wrong with not being up to handling C++'s error messages. I don't feel up to that task myself most of the time. But your arguments for Go rang hollow. I'd urge you to go through the "pro-Go" arguments point by point and describe why, say, they apply to Go but not to Python 3.0. And I'm not a Python zealot by any means; I mention it as a comparison point mostly becaus…

"why, say, they apply to Go but not to Python 3.0" That's sort of a terrible example since python is ill-suited to many (might I dare say a clear majority of?) production environments. The field of general-purpose production languages is actually pretty narrow. I somewhat agree with your point that the reasons were on the superficial side. Nevertheless, people are dissatisfied with the C/C++/JAVA trio and efforts to…

* python is ill-suited to many (might I dare say a clear majority of?) production environments *

A bold statement, considering the broad range of production environments that have come to the opposite conclusion.

Do you have anything in specific to back up this claim or is this just name-calling?

Re: Go is amazing, period.

#200
If you are going to create a headline that ends with ", period." the content of the article had better contain a cohesive and very strong argument that supports the emphasized statement. You could have easily posted - "Go is amazing." That is a statement of opinion -- which pretty well describes the article and the author's place as an expert. "Go is amazing, period." claims something much deeper, which the article completely fails to deliver.
Post reply on HN