What is the point of using 'forward'
#2

forward announce the compiler that you defined a function somewhere down in the code:
for example

THIS IS WRONG!!!
Код:
//somewhere in the code;
function(a,b);

//function is defined after the call
stock function()
{
// do something;
}

So you can't call a function if you didn't define it previously only if you use forward
This is correct
Код:
forward function(x,y);
//somewhere in the code;
function(x,y);

//function is defined after the call
stock function(a,b)
{
// do something;
}
Reply


Messages In This Thread
What is the point of using 'forward' - by K9IsGodly - 12.03.2014, 20:53
Re: What is the point of using 'forward' - by radyx - 12.03.2014, 21:05
Re: What is the point of using 'forward' - by dannyk0ed - 12.03.2014, 21:09
Re: What is the point of using 'forward' - by AnonScripter - 12.03.2014, 21:10
Re: What is the point of using 'forward' - by CuervO - 12.03.2014, 21:11

Forum Jump:


Users browsing this thread: 1 Guest(s)