Skip to content

Commit

Permalink
remove dead code
Browse files Browse the repository at this point in the history
  • Loading branch information
Godones committed Feb 7, 2024
1 parent 87a3f05 commit dc10810
Show file tree
Hide file tree
Showing 2 changed files with 1 addition and 35 deletions.
35 changes: 1 addition & 34 deletions kernel/src/print.rs
Original file line number Diff line number Diff line change
Expand Up @@ -73,37 +73,4 @@ impl Screen {
pub fn new() -> Self {
Self {}
}
}
//
// impl Write for Screen{
// fn write_str(&mut self, s: &str) -> core::fmt::Result {
// VBEDRIVER.lock().print_string(s);
// Ok(())
// }
// }
//
// lazy_static! {
// pub static ref SCREEN: Mutex<Screen> = Mutex::new(Screen::new());
// }
//
//
// pub fn s_print(arg: Arguments) {
// SCREEN.lock().write_fmt(arg).unwrap()
// }
// ///借用标准库的print!实现
// /// $crate 变量使得我们不必在使用println!时导入宏
// #[macro_export]
// /// print string macro
// macro_rules! sprint {
// ($fmt: literal $(, $($arg: tt)+)?) => {
// $crate::print::s_print(format_args!($fmt $(, $($arg)+)?));
// }
// }
//
// #[macro_export]
// /// println string macro
// macro_rules! sprintln {
// ($fmt: literal $(, $($arg: tt)+)?) => {
// $crate::print::s_print(format_args!(concat!($fmt, "\n") $(, $($arg)+)?));
// }
// }
}
1 change: 0 additions & 1 deletion kernel/src/task/mod.rs
Original file line number Diff line number Diff line change
Expand Up @@ -151,7 +151,6 @@ lazy_static! {
}

pub fn add_initproc() {
println!("add initproc to task manager");
let _initproc = INITPROC.clone();
}

Expand Down

0 comments on commit dc10810

Please sign in to comment.