type checking !?!?

This commit is contained in:
2025-03-22 14:40:32 -04:00
parent 606cb30c6b
commit 7f809d797c
44 changed files with 664 additions and 314 deletions
+27
View File
@@ -0,0 +1,27 @@
use crate::{common::FileSpan, ir::VarID};
use std::fmt::Debug;
use super::IRUInstruction;
#[derive(Clone, Copy)]
pub struct VarInst {
pub id: VarID,
pub span: FileSpan,
}
pub struct IRUInstrInst {
pub i: IRUInstruction,
pub span: FileSpan,
}
impl Debug for VarInst {
fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
write!(f, "{:?}", self.id)
}
}
impl Debug for IRUInstrInst {
fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
write!(f, "{:?}", self.i)
}
}