inline-rust icon indicating copy to clipboard operation
inline-rust copied to clipboard

Top-level reference types

Open harpocrates opened this issue 7 years ago • 1 comments

References at the top level should be possible. For example:

main = do
  let s: S = {- some complex deeply nested struct (but not enum!) -}
  [rustIO| () { println!("{:#?}", (&s: &S)) } |]

Under the hood, this should turn into a Ptr S which gets unsafely turned into a reference on the Rust side.

harpocrates avatar Mar 18 '18 21:03 harpocrates

Types that we will want to have in this category:ByteString, ByteArray, ByteArray#, MutableByteArray, MutableByteArray#, StorableVector.

harpocrates avatar Apr 01 '18 20:04 harpocrates