stdio: add print

This commit is contained in:
Astro 2019-06-21 01:18:24 +02:00
parent e5881a14ad
commit 80f003b2c6
1 changed files with 9 additions and 0 deletions

View File

@ -18,6 +18,15 @@ pub fn get_uart() -> &'static mut Uart {
}
}
#[macro_export]
macro_rules! print {
($($arg:tt)*) => ({
use core::fmt::Write;
let uart = crate::stdio::get_uart();
write!(uart, $($arg)*);
})
}
#[macro_export]
macro_rules! println {
($($arg:tt)*) => ({