This commit is contained in:
Yifan Wu 2020-12-14 16:18:33 +08:00
parent e93a4a0b76
commit 2d34cab989
14 changed files with 218 additions and 18 deletions

View file

@ -11,10 +11,11 @@ pub trait File : Any + Send + Sync {
}
impl dyn File {
#[allow(unused)]
pub fn downcast_ref<T: File>(&self) -> Option<&T> {
self.as_any_ref().downcast_ref::<T>()
}
}
pub use pipe::{Pipe};
pub use pipe::{Pipe, make_pipe};
pub use stdio::{Stdin, Stdout};