Ok, I had a test program that used a few other units. Apparently this had to be placed at the top of my units that used and implemented the nested callback type.

{$mode objfpc}
{$modeswitch nestedprocvars}


The last question I have is when can I expect to use nested procedure variables system wide without compiler directives? What's the hold-up or reason why the mode is even needed?

Thanks again,

On 11/23/2013 09:43 AM, Jonas Maebe wrote:
On 23 Nov 2013, at 15:47, Andrew Brunner wrote:

I'm wondering if the is nested procedure type is supposed to work

{$modeswitch nestedprocvars}

Type TMyCallback=procedure(Index:Integer) is nested;

I thought 2.6.0 was supposed to support this but I'm using FPC from svn/trunk 
and it does not.  Any ideas?
It does work, see e.g. 
http://svn.freepascal.org/svn/fpc/trunk/tests/test/tmaclocalprocparam2d.pp


Jonas_______________________________________________
fpc-pascal maillist  -  fpc-pascal@lists.freepascal.org
http://lists.freepascal.org/mailman/listinfo/fpc-pascal
_______________________________________________
fpc-pascal maillist  -  fpc-pascal@lists.freepascal.org
http://lists.freepascal.org/mailman/listinfo/fpc-pascal

Reply via email to