add debug attributes back in

This commit is contained in:
bunnie 2021-01-17 17:02:40 +08:00
parent b6efb15488
commit 5701bf4968

View file

@ -50,7 +50,15 @@ pub struct TextView<'a> {
canvas: [u32; 4], // GID of the canvas to draw on
}
//#[derive(Debug)]
impl<'a> core::fmt::Debug for TextView<'a> {
fn fmt(&self, f: &mut core::fmt::Formatter<'_>) -> core::fmt::Result {
// this should definitely be extended to print more relevant data, but for now just render the string itself
write!(f, "{}", self.text)
}
}
#[derive(Debug)]
pub enum Opcode<'a> {
// clears a canvas with a given GID
ClearCanvas([u32; 4]),