On Thu, Nov 19, 2009 at 20:31, Jonas Maebe <jonas.ma...@elis.ugent.be> wrote: > > On 19 Nov 2009, at 11:21, Alexander Klenin wrote: > >> On Thu, Nov 19, 2009 at 19:20, Martin <laza...@mfriebe.de> wrote: >> >>> Jonas Maebe wrote: >> >> [skipped example] >> >>> Well in this case, the code is actually positively affected by the "out" >>> param (because it avoids the mem leak) >> >> Jonas, can you confirm that your example is incorrect one, >> and Martin's example below is actually what you meant? > > Why do you think my example is incorrect? It currently runs without a memory > leak, and would result in a memory leak if the semantics of "out" would be > changed from "parameters are automatically finalized at the caller side" > into "no finalization is performed".
I think that nobody argued against the semantics of "out" parameters -- IMHO the current semantics is good. > You did ask for an example where changing the semantics of "out" would > change the behaviour of existing code, didn't you? No, I asked for an example of code that would be negatively affected by changing "var" to "out" in FillChar parameter. -- Alexander S. Klenin _______________________________________________ fpc-devel maillist - fpc-devel@lists.freepascal.org http://lists.freepascal.org/mailman/listinfo/fpc-devel