Better HN
topnewbestaskshowjobs
Log inSign up

enneff

14,622 karma · joined Jan 27, 2009 (17y ago) · 2,278 submissions

adg at golang dot org
Submissions

comment 16y ago · link · parent

We initially called Go a "systems language," because we wanted to use it to build systems software. What we mean by that is high-performance networked programs that run on multicore machines. The kind of server stuff people traditionally use C or C++ for. Since Go's release last November, we've seen interest in Go from a lot of different places. There was the high-performance computing crowd that we were targeting, but beyond that we saw a lot of users of interpreted languages who craved more speed with the same ease-of-use.

We're yet to see which major niche Go fills, if any. There's a growing community of people from different backgrounds using it, and they seem to enjoy it. I personally think it's a lovely language to write all kinds of code in. I recently rewrote our continuous build client in Go, and I found it a cinch to write it in clear, reliable, maintainable way. It's definitely worth checking Go out because, even though it ticks a lot of the same boxes as existing languages, it's quite different from anything else out there in many subtle ways. Certainly for writing server daemons it totally kicks ass.

It's easy to get started. The standard library is featureful (http://golang.org/pkg/), and there's a lot of good documentation (http://golang.org/doc/docs.html). As for integrating with existing code, Go comes with a tool called cgo (http://golang.org/cmd/cgo/) which allows you to write Go code that links with C code. It's pretty easy to use, and there are many third party libraries (http://godashboard.appspot.com/project) that use it. There's also Go support for SWIG for linking against C++ code.

comment 16y ago · link · parent

Ideone is pretty cool, although it seems slower, and the editor doesn't indent.

Also, it's running a _really_ old version of Go. (http://ideone.com/spBzw) It's at least 400 revisions out of date. We intend to keep the golang.org Playground up-to-date.

comment 16y ago · link · parent

When searching is fast, you're more inclined to refine your search terms, hence you do more searches. Seems a pretty straightforward concept.

2074.

Introducing the Go Playground(blog.golang.org ↗)

76 points · by enneff · 16y ago · 31 comments

comment 16y ago · link · parent

I modded you down for this: "Besides, this guy just looks creepy."

comment 16y ago · link · parent

I can tell you that it does NOT typically happen at Google. If you so much as joke about this stuff people will give you negative reactions. I was genuinely shocked to read about this today as I never would have expected any Google employee to be so unethical.

If what you say about the practices at Facebook is even remotely true then it is disgusting and shameful behaviour.

comment 16y ago · link · parent

I've recently been seeing an Osteopath, and I've been really delighted that his administrative staff have twice contacted me a couple of hours before appointments to reschedule (by 30-40 minutes) as his schedule had slipped during the day. I haven't spent more than 1 or 2 minutes waiting for him. It's kind-of sad that this level of service is remarkable rather than customary.

comment 16y ago · link · parent

"Everything is Async: Because the base environment has been built essentially from scratch, everything is asynchronous. This means there is no ‘defer to thread’ like in Twisted Python; You just can’t make blocking code."

This is not necessarily a good thing. Sometimes you need to write a piece of code that executes sequentially. Having the ability to do that if you need to is a good thing. Sometimes it can be unnatural and unwieldy to split a block of functionality up into a set of callback functions.

comment 16y ago · link · parent

"So this is a program that has to run with reasonable performance on a 12MHz 80286 with 2MB of RAM. Are you sure you wouldn't consider having your UI read and write the disk directly?"

I wrote code for those machines, and no, I wouldn't write my UI code to read and write the disk directly.

"Separation of concerns is a modern luxury."

This is a myth. Merely an excuse for poor API design. Proper abstraction doesn't mean inefficiency.

Your last paragraph (the "Edit") is almost offensive. The cause of bloat is not separation of concerns. It's that people just don't care about writing efficient code (or they just don't know how). Did you ever write code in the era you speak of? Because your statement comes across as ill-informed conjecture.

comment 16y ago · link · parent

"To get the most performance out of the PCs of the day, I believe he had the register itself more or less directly read and write transaction data from disk."

I don't buy this excuse. It just sounds like bad code to me.

comment 16y ago · link · parent

"Other archive formats like WinZip..."

The guy immediately loses credibility in my eyes for referring to the most popular archive format as 'WinZip'. It's the ZIP file format, designed by Phil Katz of PKWare Inc.

http://en.wikipedia.org/wiki/ZIP_(file_format)

To add injury to insult, the rest of his proposal is pretty similar to ZIP, which also accomplishes the nice-to-have things he mentions at the end.

comment 16y ago · link · parent

Version control is also fantastic because you can think a lot less about making drastic edits. Gone are the days when I would keep bits of code commented out "just in case" I needed it back at some point.

comment 16y ago · link · parent

I'd rather not have my tools perform magical heuristics to try to figure out what I meant to do.

The "-f <filename>" flag is perfectly clear, and useful in all modes (c, x, etc). If you remember "tar czf" as a magical incantation, then you're missing something vital. When you understand what each argument means there is no ambiguity. I don't mean to sound condescending, but in my entire life I've never encountered the problem you described.

comment 16y ago · link · parent

Pertinent quotes:

"The trick is to control the urge to put in every feature that comes to mind. It's also important to worry more about semantics than syntax."

"Consensus drove the design. Nothing went into the language until all three of us agreed that it was right. This meant that some features didn't get resolved until after a year or more of discussion."

2085.

All Systems Are Go: An Interview with Rob Pike(informit.com ↗)

28 points · by enneff · 16y ago · 3 comments

comment 16y ago · link · parent

My partner is also an artist, and I am a programmer. Funny.

comment 16y ago · link · parent

"I suspect this process is well under way at Google these days."

What's your basis for this speculation?

comment 16y ago · link · parent

How is online currency _not_ relevant to Hacker News?

comment 16y ago · link · parent

"There's a number of programmers who really seem to dislike exceptions: Joel Spolsky and Rob Pike among them."

Additionally, the Google C++ style guide forbids the use of exceptions.

comment 16y ago · link · parent

"it would be ad hoc and limit library interoperability."

Panicking across package boundaries is unidiomatic, a bad idea, and explicitly warned against in the blog post.

comment 16y ago · link · parent

Actually, you can recover from specific types of errors. Check the value returned from recover(), and if it's not what you want to handle, panic(value).

comment 16y ago · link · parent

That's my point.

comment 16y ago · link · parent

"Speak for yourself."

I did: "I think" "I associate" "I look" "I clicked" "I'm not"

comment 16y ago · link · parent

If all she wants to do is get page views, then she's succeeding.

By positioning herself as a "girl", I think of her as a girl first, and a developer second. What qualities do I associate with girls? Not the qualities I look for in a programming blogger. Is that prejudice? I guess so.

I clicked the link because it had a catchy title, not because it was from a site "girldeveloper". That I'm not even thinking about the content of the post anymore speaks volumes.

2095.

OSCON 2010: Rob Pike, "Public Static Void"(youtube.com ↗)

3 points · by enneff · 16y ago · 2 comments

comment 16y ago · link · parent

"The stereotype of the antisocial developer has been untrue for decades"

It has _never_ been true.

comment 16y ago · link · parent

Is "man ssh" really that hard? Is it necessary to reproduce the excellent documentation that already exists?

comment 16y ago · link · parent

"Yeah, no. Of the dozens of Googlers I've met, their take is that this is just not the case."

I am a Googler. I mentioned explicitly that false negatives happen, and stated why they are preferable. Why, then, do you preface your comment with a disagreement?

comment 16y ago · link · parent

"As a recent hire at Google, I don't really think this is the case. There's not just a bias towards false negatives, there's a strong bias. It's well understood here that lots of qualified people are turned away."

This is pretty much exactly what I said. Do you think if I'd pointed out that I'm actually a google employee also, I might have been spared the down votes?

comment 16y ago · link · parent

"But the process does seem to be a lottery to some extent."

They go to great lengths to ensure this is not the case. If the feedback from five different interviewers led to a 'no hire' decision, the chances are good that it was the right decision. Of course, no system is perfect. They tend to err on the side of exclusivity; it's much cheaper to decline a suitable candidate than it is to hire someone who won't work out in the long term.

1
697071
76