How on earth did they decide this was a good idea? The points about getting rid of register_globals and safe_mode are great, but why add a feature to a programming language that is highly likely just to result in lots of awful code?
How on earth did they decide this was a good idea? The points about getting rid of register_globals and safe_mode are great, but why add a feature to a programming language that is highly likely just to result in lots of awful code?
I've seen this problem "solved" with a do while false and a break, but isn't that even hackier and less expressive?
At this point I think goto-phobia is well understood enough that adding it for occasional use wouldn't ruin the language.
[Direct to comic] http://imgs.xkcd.com/comics/goto.png
By the way, the docs on that page are way out of date so if anyone is interested feel free to contact me.
EDIT: I'm an idiot, for tail calls of course it's a bit more complicated than just using a loop.