Fix type errors introducent by recent Rust changes.