Unable to pass a D function member to a C callback

Dennis dkorpel at gmail.com
Sat Nov 2 21:17:45 UTC 2019


On Saturday, 2 November 2019 at 20:42:29 UTC, Luh wrote:
> Yup that's it !
> Many thanks !

One word of warning: ensure the C library does not have the only 
reference to your Game class instance, or the garbage collector 
might deallocate it since it does not scan threads created by C 
libraries.

See:
https://dlang.org/spec/garbage.html#gc_foreign_obj


More information about the Digitalmars-d-learn mailing list