We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
.nth(0)
1 parent 172ba42 commit 4ce0eb1Copy full SHA for 4ce0eb1
examples/cli.rs
@@ -40,7 +40,7 @@ fn main() {
40
println!("Parsing from file '{}' using {:?}", &filename, dialect);
41
let contents = fs::read_to_string(&filename)
42
.unwrap_or_else(|_| panic!("Unable to read the file {}", &filename));
43
- let without_bom = if contents.chars().nth(0).unwrap() as u64 != 0xfeff {
+ let without_bom = if contents.chars().next().unwrap() as u64 != 0xfeff {
44
contents.as_str()
45
} else {
46
let mut chars = contents.chars();
0 commit comments