Haskell calling D code through the FFI

Jon via Digitalmars-d-learn digitalmars-d-learn at puremagic.com
Mon Aug 4 14:35:20 PDT 2014


I get Error: core.runtime.rt_init is private.  And Error: 
core.runtime.init is not accessible.

On Monday, 4 August 2014 at 21:22:37 UTC, safety0ff wrote:
> On Monday, 4 August 2014 at 21:14:17 UTC, Jon wrote:
>> On Monday, 4 August 2014 at 21:10:46 UTC, safety0ff wrote:
>>> Don't forget to call rt_init: 
>>> http://dlang.org/phobos/core_runtime.html#.rt_init
>>
>> Where/when should I call this?
>
> Before calling any D functions, but usually it's simplest to 
> call it early in main.
>
> It initializes the GC and notifies the D runtime of its 
> existence.
> For simple D functions you might get away without calling it.



More information about the Digitalmars-d-learn mailing list