On the other hand, there are good reasons to use gotos, such as
readability, maintainability and the like (reliability? My code is
less reliable if I use a goto? huh?). While I agree that those don't
really apply to a 5 line function, this is a common idiom within the
linux kernel for very good reasons.
Try tidying up some of the functions in the vfs to not use goto and watch
your indentation disappear off the end of your screen, your neighbour's
screen and out of the window. I tried this once and came out a changed
man, convinced of the usefulness of goto.
Yes, of course you can make a mess with goto. Don't do that.
-- Matthew Wilcox <willy@bofh.ai> "Windows and MacOS are products, contrived by engineers in the service of specific companies. Unix, by contrast, is not so much a product as it is a painstakingly compiled oral history of the hacker subculture." - N Stephenson- To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a message to majordomo@vger.rutgers.edu Please read the FAQ at http://www.tux.org/lkml/