Clippy
This commit is contained in:
parent
ac6b76b4d1
commit
7c5107921d
|
@ -1,5 +1,6 @@
|
||||||
//! Common color structures used in vga.
|
//! Common color structures used in vga.
|
||||||
|
|
||||||
|
/// Represents the size of the vga palette in bytes.
|
||||||
pub const PALETTE_SIZE: usize = 768;
|
pub const PALETTE_SIZE: usize = 768;
|
||||||
|
|
||||||
/// Represents a 16 bit color used for vga display.
|
/// Represents a 16 bit color used for vga display.
|
||||||
|
|
|
@ -426,9 +426,9 @@ impl ColorPaletteRegisters {
|
||||||
unsafe {
|
unsafe {
|
||||||
self.index_read_port.write(0);
|
self.index_read_port.write(0);
|
||||||
}
|
}
|
||||||
for i in 0..PALETTE_SIZE {
|
for byte in palette.iter_mut().take(PALETTE_SIZE) {
|
||||||
unsafe {
|
unsafe {
|
||||||
palette[i] = self.data_port.read();
|
*byte = self.data_port.read();
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in a new issue