Clean up warnings and formatting.

This commit is contained in:
2022-12-29 14:50:56 -08:00
committed by Adam Wick
parent e6a488012c
commit a426a4754a
10 changed files with 46 additions and 53 deletions

View File

@@ -3,15 +3,12 @@ use codespan_reporting::diagnostic::Diagnostic;
use codespan_reporting::files::SimpleFiles;
use codespan_reporting::term;
use codespan_reporting::term::termcolor::{ColorChoice, StandardStream};
use cranelift_codegen::ir::{types, AbiParam, Signature};
use cranelift_codegen::isa::CallConv;
use cranelift_codegen::{isa, settings, CodegenError};
use cranelift_module::{default_libcall_names, Linkage, Module, ModuleError};
use cranelift_module::{default_libcall_names, ModuleError};
use cranelift_object::{object, ObjectBuilder, ObjectModule};
use ngr::asts::lil;
use ngr::passes::{run_front_end, BackendError};
use ngr::runtime::RuntimeFunctions;
use pretty::Arena;
use std::io;
use target_lexicon::Triple;
use thiserror::Error;
@@ -78,7 +75,7 @@ fn main() -> Result<(), MainError> {
if let Some((hil_tree, variable_map)) = hil_conversion_result.result {
//let arena = Arena::new();
let lil_tree = lil::Program::convert(hil_tree, variable_map.clone());
let lil_tree = lil::Program::convert(hil_tree, variable_map);
let isa = isa::lookup(Triple::host())?.finish(settings::Flags::new(settings::builder()))?;
let object_builder = ObjectBuilder::new(isa, "example", default_libcall_names())?;