style: cargo fmt kernel crates
This commit is contained in:
@@ -6,7 +6,9 @@ pub struct Uart {
|
||||
|
||||
impl Uart {
|
||||
pub fn new() -> Self {
|
||||
Self { base: board::UART_BASE }
|
||||
Self {
|
||||
base: board::UART_BASE,
|
||||
}
|
||||
}
|
||||
|
||||
pub fn put_char(&self, byte: u8) {
|
||||
@@ -30,7 +32,11 @@ impl Uart {
|
||||
let mut i = 0;
|
||||
while value > 0 {
|
||||
let digit = (value & 0xF) as u8;
|
||||
buf[i] = if digit < 10 { b'0' + digit } else { b'a' + digit - 10 };
|
||||
buf[i] = if digit < 10 {
|
||||
b'0' + digit
|
||||
} else {
|
||||
b'a' + digit - 10
|
||||
};
|
||||
value >>= 4;
|
||||
i += 1;
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user