Fix warnings in rust example