Fix clippy

This commit is contained in:
howardwu 2021-02-04 19:34:19 -08:00
parent 4d5ff0b962
commit 79ce27b861

View File

@ -110,7 +110,7 @@ impl Asg {
// TODO (howardwu): Remove this.
pub fn load_asg<T: ImportResolver + 'static>(content: &str, resolver: &mut T) -> Result<Program, AsgConvertError> {
// Parses the Leo file and constructs a grammar ast.
let ast = leo_grammar::Grammar::new(&Path::new("input.leo"), content.as_ref())
let ast = leo_grammar::Grammar::new(&Path::new("input.leo"), content)
.map_err(|e| AsgConvertError::InternalError(format!("ast: {:?}", e)))?;
InternalProgram::new(leo_ast::Ast::new("load_ast", &ast)?.as_repr(), resolver)