summaryrefslogtreecommitdiffstats
path: root/src/parse
diff options
context:
space:
mode:
authorJesse Luehrs <doy@tozt.net>2022-01-10 00:57:02 -0500
committerJesse Luehrs <doy@tozt.net>2022-01-10 00:57:02 -0500
commit63d9cd178954a65bd0616ff75164de9872004197 (patch)
tree6171c5fe0f8da1599bff620345608a540c646ea3 /src/parse
parent870c86f4eb5c7a95d169ea564dd1ee205df34c1a (diff)
downloadnbsh-63d9cd178954a65bd0616ff75164de9872004197.tar.gz
nbsh-63d9cd178954a65bd0616ff75164de9872004197.zip
improve parsing error messages
Diffstat (limited to 'src/parse')
-rw-r--r--src/parse/ast.rs2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/parse/ast.rs b/src/parse/ast.rs
index d331863..9cf583a 100644
--- a/src/parse/ast.rs
+++ b/src/parse/ast.rs
@@ -15,7 +15,7 @@ impl Commands {
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, anyhow::anyhow!(e)))?
+ .map_err(|e| super::Error::new(full_cmd, e))?
.next()
.unwrap()
.into_inner()