Remove some deadcode and tqdm

This commit is contained in:
Janggun Lee
2025-02-26 20:20:54 +09:00
parent 0b01588b6d
commit 6f18d77861
5 changed files with 6 additions and 42 deletions

View File

@@ -5,7 +5,6 @@ use ordered_float::OrderedFloat;
use thiserror::Error;
use crate::ir::*;
use crate::*;
#[derive(Debug, PartialEq, Clone)]
pub enum Value {

View File

@@ -3,9 +3,9 @@ use std::path::Path;
use lang_c::*;
use crate::Translate;
use crate::ir::*;
use crate::utils::AssertSupported;
use crate::{Translate, *};
peg::parser! {
grammar ir_parse() for str {

View File

@@ -1,5 +1,3 @@
use crate::*;
mod deadcode;
mod gvn;
mod mem2reg;

View File

@@ -194,9 +194,11 @@ pub fn test_irgen(path: &Path) {
println!("clang (expected): {}, kecc: {}", status as u8, value as u8);
if status as u8 != value as u8 {
let mut stderr = io::stderr().lock();
stderr.write_fmt(format_args!(
"[irgen] Failed to correctly generate {path:?}.\n\n [incorrect ir]"
));
stderr
.write_fmt(format_args!(
"[irgen] Failed to correctly generate {path:?}.\n\n [incorrect ir]"
))
.unwrap();
write(&ir, &mut stderr).unwrap();
drop(stderr);
panic!("[irgen]");