Hello, enthusiastic Rust newbie here
I’m trying to get my head around the pros and cons of using FFI (Foreign Function Interface) or C extensions to call Rust from Ruby code.
I’ve seen a few talks, including one by by @steveklabnik about calling Rust from Ruby using C extensions and came across some wrapper libraries such as Helix that help reduce the cognitive overhead induced by the boilerplate code required to create extensions.
I’ve also read about FFI (Foreign Function Interface). The code examples I’ve studied seem much more simple to implement. There seems to be also some advantages with FFIs, such as the ease of installation (no compilation required by the user) and portability to other ruby implementations.
What are the pros of C extensions over FFI? Why do talks from Rust core team members revolve around the former instead of the latter? What did I miss?