Make summary function non-generic (#404)

This commit is contained in:
Casey Rodarmor 2019-04-15 13:21:35 -07:00 committed by GitHub
parent 50d4323f43
commit a2e55ef40e
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -20,9 +20,7 @@ use std::{
use crate::{expression, fragment, justfile::Justfile, parameter, parser::Parser, recipe}; use crate::{expression, fragment, justfile::Justfile, parameter, parser::Parser, recipe};
pub fn summary(path: impl AsRef<Path>) -> Result<Result<Summary, String>, io::Error> { pub fn summary(path: &Path) -> Result<Result<Summary, String>, io::Error> {
let path = path.as_ref();
let text = fs::read_to_string(path)?; let text = fs::read_to_string(path)?;
match Parser::parse(&text) { match Parser::parse(&text) {