Hi, with the C backend, the code below updates ptr in-place. However, with the FFI backend, ptr is unchanged (with both JRuby and TruffleRuby).
require "fiddle"
ptr = Fiddle::Pointer["hello"]
i = ptr.to_i
ptr.ref[0, Fiddle::SIZEOF_VOIDP] = Fiddle::Pointer["world"]
p ptr.to_i == i # false for C backend, true for FFI backend
I'm having trouble finding the cause (to try to make the behavior consistent), so wanted to see if anyone had ideas.