[fpc-pascal] _Release call location for unused function results

Maciej Izak hnb.code at gmail.com
Tue Jan 30 00:19:38 CET 2018

2018-01-29 23:32 GMT+01:00 Zoƫ Peterson <zoe at scootersoftware.com>:

> Is Free Pascal's behavior intentional?  Can it be changed to match Delphi?

the topic is well known. I have plan to add new modeswitch for that:


If you like you can try existing patch:


anyway somehow Delphi (undocumented) way seems bad. SCOPEDINTERFACEDESTROY
would be big help for legacy code ported from Delphi...

FPC has more elegant alternative way for the same thing, you can simple use

procedure Foo;
  WriteLn('Foo >');
  with Bar do
    WriteLn('Foo <');

Best regards,
Maciej Izak
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.freepascal.org/pipermail/fpc-pascal/attachments/20180130/ae7f82fd/attachment.html>

More information about the fpc-pascal mailing list