Quote:
|
Rather than using call to jump to the function, which pushes the PC onto the stack, you could just use goto, which just jumps striaght there.
|
If we're talking about useless things, might as well hit on the GOTO command. Why use goto for that situation instead of just using a for or while loop or any of their variations (for(;;), while(1), do-while, etc.)? Goto is a useless command. I cannot think of one situation where the taske cannot be better performed with some sort of loop. As far as i know, there has only been one situation found where go must be used to get the desired effect, i.e. break, continue, or loops will not work, and that was discovered by some fulltime programmer who was dedicating his time to finding it. So, to close up a long winded soapboxing, don't use goto.
edit: ok, that's not supposed to be a winking smiley, but a semicolon then a closed parenthesese, just accept it. Smilies.... arggh!
edit #2: as i clicked ok, i realized there was a disable smilies button, so now it works.