Pass BM function pointers to C/C++ code

BlitzMax Forums/BlitzMax Programming/Pass BM function pointers to C/C++ code

Hi,

That will work because BMX does auto function ptr->byte ptr casting, but a 'safer' way would be...

Extern
Function RegisterCallback( func( char:byte ptr ) )
End Extern

...which would prevent you from accidentally passing the wrong 'type' of function to RegisterCallback.