News for hackers. Stuff that matters.
Re:Porting the Go compiler from C to Go by coldtea on Friday April 25, 2014 @02:06PM (#7648098)
>but for something written in the last couple of years to have over a thousand of them is very surprising

Hardly surprising. Gotos will be found by the hundrends or thousands in C projects like compilers, kernels etc.

It's used for localized consolidated error handling, but also for stuff like parsing code (bison generates tons of gotos IIRC), state machines, etc.

If anything it's the old "Goto statement considered harmful" that's a little too naive.

Re:Porting the Go compiler from C to Go by copergi on Friday April 25, 2014 @06:51PM (#7649570)
>If anything it's the old "Goto statement considered harmful" that's a little too naive.

No, people who didn't read it and just repeat the title without knowing what he was talking about may be too naive, but the original point was not.