Cargoified & updated for the latest Rust.