Add Rust implementation.