[fpc-pascal] Out of scope method?

Ryan Joseph ryan at thealchemistguild.com
Thu Apr 6 12:28:04 CEST 2017


> On Apr 6, 2017, at 5:09 PM, Marco van de Voort <marcov at stack.nl> wrote:
> 
> No, since you don't declare an interface variable, but a class variable.
> 
> There are a zillion Delphi faqs about this, but the crux is to use
> 
> var
>  scope:IInterface;
> 
> And reference counting as garbage collection method has been discussed to
> dead on various maillists and forums. Both Delphi and Lazarus/FPC.

Hmm, that sounds like a hack. Is the verdict this is generally a bad idea? I was just curious about it and it seems like a reasonable feature a language may have.

Regards,
	Ryan Joseph




More information about the fpc-pascal mailing list