Use new Path "constructor"

This commit is contained in:
KokaKiwi 2013-10-18 14:16:00 +02:00
parent f1ca63f280
commit 287eabd4f7

View file

@ -175,7 +175,7 @@ fn open(path: ~str) -> Option<@Reader> {
return Some(stdin());
}
match std::io::file_reader(&std::path::Path(path)) {
match std::io::file_reader(&std::path::Path::new(path.as_slice())) {
Ok(fd) => return Some(fd),
Err(e) => {
stderr().write_line(fmt!("cat: %s: %s", path, e));