how do I pass this callback?

Marc jckj33 at gmail.com
Thu Mar 8 17:38:19 UTC 2018


On Thursday, 8 March 2018 at 17:06:05 UTC, Marc wrote:
> How do I define the callback so that it can be used in 
> RegisterWaitForSingleObject()?
>
> I've tried pass as argument:
>
> myFunc
> &myFunc
> myFunc.ptr
>
> none worked. Here's my code:
>
>>[...]
>
> Function call:
>
>> [...]
>
> Error:
>
>> [...]

Solved! I shall rather use extern (Windows) not extern(C):

>extern (Windows) void OnExited(void* context, BOOLEAN isTimeOut);


More information about the Digitalmars-d-learn mailing list