Defining Generic Functions in Rust