
28 Jul
2017
28 Jul
'17
3:05 a.m.
I have a blogpost which demonstrates this https://purelyfunctional.org/posts/2016-05-20-dynamic- loading-haskell-module.html
Hey Moritz, I'm not sure if you realised, but my code is based on your blog post itself -- thanks for writing it! It was just that I was trying to avoid using the `mangleSymbol` function by hard-coding the known symbol value. If I use the `mangleSymbol` method, the symbol lookup fails. If I hard-code the symbol name and try executing the function it segfaults. I'm stuck now and don't know enough about the internals of Ptr, FuncPtr, Any, etc. to figure out how to proceed. I'm on MacOSX if that makes any difference. -- Saurabh.