You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
This is a theoretical question and perhaps not the best place to ask except I wanted to hear the author's perpsective: to what extent could one achieve memory safety (with Haskell FFI + inline-rust) if one were to
Use inline-rust for all FFI calls.
Avoid using any Foreign.Ptr.* calls (or any other functions) which have the capacity to manipulate pointers from outside the purview of the rust compiler.
If one followed these two rules, could one achieve memory safety in a Haskell project that uses lots of FFI?
The text was updated successfully, but these errors were encountered:
I think it sort of depends on what exactly you mean with 'memory safety'. Haskell's lazy nature means that you can create ridiculously large thunks that will end up never being resolved/used but might stick around in memory.
This is a theoretical question and perhaps not the best place to ask except I wanted to hear the author's perpsective: to what extent could one achieve memory safety (with Haskell FFI + inline-rust) if one were to
Foreign.Ptr.*
calls (or any other functions) which have the capacity to manipulate pointers from outside the purview of the rust compiler.If one followed these two rules, could one achieve memory safety in a Haskell project that uses lots of FFI?
The text was updated successfully, but these errors were encountered: