Learn from clippy.

This commit is contained in:
2020-12-11 10:46:45 -08:00
parent 3e31c00505
commit a2b48b59b4
4 changed files with 9 additions and 7 deletions

View File

@@ -116,7 +116,7 @@ fn third_example() {
}
fn main() -> Result<(), TopLevelError> {
let filename = env::args().skip(1).next().expect("No file argument given.");
let filename = env::args().nth(1).expect("No file argument given.");
let contents = fs::read_to_string(filename)?;
let mut xmas_checker = XmasChecker::new(25);