asm output, random fixes

This commit is contained in:
2025-04-07 19:42:40 -04:00
parent f57af3b2b5
commit cb9a366f43
18 changed files with 266 additions and 117 deletions

View File

@@ -3,11 +3,7 @@ use crate::ir::{IRUProgram, Origin, Type, VarDef};
use super::{CompilerMsg, CompilerOutput, FileSpan, Node, PType, PVarDef};
impl Node<PVarDef> {
pub fn lower(
&self,
program: &mut IRUProgram,
output: &mut CompilerOutput,
) -> Option<VarDef> {
pub fn lower(&self, program: &mut IRUProgram, output: &mut CompilerOutput) -> Option<VarDef> {
let s = self.as_ref()?;
let name = s.name.as_ref()?.to_string();
let ty = match &s.ty {
@@ -17,7 +13,7 @@ impl Node<PVarDef> {
Some(VarDef {
name,
ty,
origin: Origin::File(self.span),
origin: self.span,
})
}
}