Is it possible to dynamically load a @safe function from a shared library ?
wjoe
invalid at example.com
Fri Mar 13 16:11:53 UTC 2020
On Friday, 13 March 2020 at 16:04:06 UTC, Mike Parker wrote:
> On Friday, 13 March 2020 at 15:16:06 UTC, wjoe wrote:
>
>> bindSymbol(&apiVersion, "VersionOfAPI");
>> }
>>
>
>>
>> Is it possible to convince the compiler to look the other way
>> while binding @safe functions from the plugin ?
>
> It probably has nothing to do with @safe, but is because of the
> void**.
>
> bindSymbol(cast(void**)&apiVersion, "VersionOfAPI");
Than works, thanks :)
But isn't apiVersion a function pointer ?
More information about the Digitalmars-d-learn
mailing list