You've already forked comprehensive-rust
mirror of
https://github.com/google/comprehensive-rust.git
synced 2025-11-29 08:57:20 +02:00
Add missing import for try-conversions.md example (#1986)
Uncommenting the "write" line causes the example to fail compilation because the compiler can't find `fs`.
This commit is contained in:
@@ -65,7 +65,7 @@ fn read_username(path: &str) -> Result<String, ReadUsernameError> {
|
|||||||
}
|
}
|
||||||
|
|
||||||
fn main() {
|
fn main() {
|
||||||
//fs::write("config.dat", "").unwrap();
|
//std::fs::write("config.dat", "").unwrap();
|
||||||
let username = read_username("config.dat");
|
let username = read_username("config.dat");
|
||||||
println!("username or error: {username:?}");
|
println!("username or error: {username:?}");
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user