Hello every one,
I try to embedding Julia in C# but when I call jl_init() after declaration of dllImport like, like that:
using System;
using System.Runtime.InteropServices;
namespace ConsoleApplication2
{
class Program
{
[DllImport(“libjulia.dll”)]
static extern void jl_init();
[DllImport("libjulia.dll")]
static extern void jl_eval_string(string message);
static void Main(string[] args)
{
jl_init();
jl_eval_string("print(sqrt(2.0))");
}
}
}
jl_init() crash with error System.stackoverflowexception
If I trying to bypass jl_init() and so execute directly jl_eval_string with or less pointer I have an other error message:
Unhandled Exception: System.AccessViolationException: Attempted to read or write
protected memory. This is often an indication that other memory is corrupt.
Thanks for your help !