get rid of unused braces

This commit is contained in:
Michael Zhang 2021-02-03 01:57:55 -06:00
parent 6353d4f239
commit 02011dfe44
Signed by: michael
GPG key ID: BDA47A31A3C8EE6B
2 changed files with 11 additions and 7 deletions

View file

@ -1,7 +1,7 @@
mod ast;
mod name_res;
mod parser;
mod utils;
pub mod ast;
pub mod name_res;
pub mod parser;
pub mod utils;
use std::fs::{File, OpenOptions};
use std::io::{Read, Write};
@ -35,7 +35,7 @@ fn main() -> Result<()> {
let namespaces = Namespaces::create(parsed);
println!("namespaces: {:?}", namespaces);
namespaces.name_resolution();
let tree = namespaces.name_resolution();
let isa = {
use std::str::FromStr;

View file

@ -1,9 +1,13 @@
use anyhow::Result;
use lalrpop_util::lalrpop_mod;
use crate::ast::Program;
lalrpop_mod!(parser);
mod parser {
#![allow(unused_braces)]
use lalrpop_util::lalrpop_mod;
lalrpop_mod!(parser);
pub use self::parser::*;
}
pub fn parse(s: impl AsRef<str>) -> Result<Program> {
let s = s.as_ref().to_owned();