If so, you could do:
int MyFunction{ int Result = 0; // Code-that-might-change-value-of-Result-but-you-don''t-want-to-return-from // Some code return Result;}
int MyFunction{ int Result = 0; // Code-that-might-change-value-of-Result-but-you-don''t-want-to-return-from // Some code return Result;}
quote: Original post by SabreMan
That doesn''t make any sense. If you haven''t "broken out of the function", then you haven''t returned. What is it that you are trying to achieve?
quote: Original post by Fruny
Actually, you can to stuff like that. But that involves (non-portable) stack tricks (thunks): If you use the naked specifier to, when you calle a function, the return address is topmost on the stack. So you ''just have to'' pop it and call it... so long as you make sure you don''t smash the stack.
quote: Original post by incin
umm... no params? How about a global var then? Why dont you describe what you are trying to accomplish?
quote: Oriinal post by Oluseyi
Get over it.