2022-02-21 18:58:12 -06:00
|
|
|
use std::path::{Path, PathBuf};
|
2018-12-12 18:54:27 -06:00
|
|
|
|
|
|
|
fn main() {
|
|
|
|
let path = Path::new("/tmp/foo/bar.txt");
|
|
|
|
println!("{}", path);
|
|
|
|
//~^ ERROR E0277
|
2022-02-21 18:58:12 -06:00
|
|
|
|
|
|
|
let path = PathBuf::from("/tmp/foo/bar.txt");
|
|
|
|
println!("{}", path);
|
|
|
|
//~^ ERROR E0277
|
2018-12-12 18:54:27 -06:00
|
|
|
}
|