summaryrefslogtreecommitdiffstats
path: root/src
diff options
context:
space:
mode:
authorJesse Luehrs <doy@tozt.net>2022-03-04 20:33:51 -0500
committerJesse Luehrs <doy@tozt.net>2022-03-04 20:33:51 -0500
commitf3bda2fa9643ff4ae860d6482cf0a601298300ac (patch)
tree4d0b47c5a18e1ad6b51cb764ec5e779f8ddfd695 /src
parent6e0c0679d02c20258bfabf370f5a977644eea6e7 (diff)
downloadnbsh-f3bda2fa9643ff4ae860d6482cf0a601298300ac.tar.gz
nbsh-f3bda2fa9643ff4ae860d6482cf0a601298300ac.zip
clippy
Diffstat (limited to 'src')
-rw-r--r--src/parse/ast.rs4
1 files changed, 2 insertions, 2 deletions
diff --git a/src/parse/ast.rs b/src/parse/ast.rs
index 030ce14..9c99907 100644
--- a/src/parse/ast.rs
+++ b/src/parse/ast.rs
@@ -12,10 +12,10 @@ pub struct Commands {
}
impl Commands {
- pub fn parse(full_cmd: &String) -> Result<Self, super::Error> {
+ pub fn parse(full_cmd: &str) -> Result<Self, super::Error> {
Ok(Self::build_ast(
Shell::parse(Rule::line, full_cmd)
- .map_err(|e| super::Error::new(full_cmd.clone(), e))?
+ .map_err(|e| super::Error::new(full_cmd.to_string(), e))?
.next()
.unwrap()
.into_inner()