How can I make a forward declaration of a procedure in Delphi and make it's implementation in other place? I want to do something like this C's code but in Delphi:
void FooBar();
void FooBar()
{
// Do something
}
You do that with the forward
directive, like so:
procedure FooBar(); forward;
...
//later on
procedure FooBar()
begin
// Do something
end;
This is only necessary if you're declaring it as an internal function. (ie. already inside the implementation
section of your unit.) Anything declared as a method of a class, or in the interface
section of the unit, is automatically understood to be forward-declared.