mirror of
https://github.com/nushell/nushell.git
synced 2025-06-30 22:50:14 +02:00
Fix some nightly clippy warnings (#329)
This commit is contained in:
@ -13,7 +13,7 @@ pub use lite_parse::{lite_parse, LiteBlock};
|
||||
pub use parse_keywords::{
|
||||
parse_alias, parse_def, parse_def_predecl, parse_let, parse_module, parse_use,
|
||||
};
|
||||
pub use parser::{find_captures_in_expr, parse, Import, VarDecl};
|
||||
pub use parser::{find_captures_in_expr, parse, Import};
|
||||
|
||||
#[cfg(feature = "plugin")]
|
||||
pub use parse_keywords::parse_plugin;
|
||||
|
@ -24,12 +24,6 @@ use crate::parse_keywords::parse_plugin;
|
||||
#[derive(Debug, Clone)]
|
||||
pub enum Import {}
|
||||
|
||||
#[derive(Debug, Clone)]
|
||||
pub struct VarDecl {
|
||||
var_id: VarId,
|
||||
expression: Expression,
|
||||
}
|
||||
|
||||
pub fn garbage(span: Span) -> Expression {
|
||||
Expression::garbage(span)
|
||||
}
|
||||
@ -271,7 +265,7 @@ fn parse_short_flags(
|
||||
error = error.or_else(|| {
|
||||
Some(ParseError::UnknownFlag(
|
||||
sig.name.clone(),
|
||||
format!("-{}", String::from_utf8_lossy(contents).to_string()),
|
||||
format!("-{}", String::from_utf8_lossy(contents)),
|
||||
*first,
|
||||
))
|
||||
});
|
||||
@ -281,7 +275,7 @@ fn parse_short_flags(
|
||||
error = error.or_else(|| {
|
||||
Some(ParseError::UnknownFlag(
|
||||
sig.name.clone(),
|
||||
format!("-{}", String::from_utf8_lossy(contents).to_string()),
|
||||
format!("-{}", String::from_utf8_lossy(contents)),
|
||||
*first,
|
||||
))
|
||||
});
|
||||
@ -291,7 +285,7 @@ fn parse_short_flags(
|
||||
error = error.or_else(|| {
|
||||
Some(ParseError::UnknownFlag(
|
||||
sig.name.clone(),
|
||||
format!("-{}", String::from_utf8_lossy(contents).to_string()),
|
||||
format!("-{}", String::from_utf8_lossy(contents)),
|
||||
*first,
|
||||
))
|
||||
});
|
||||
@ -302,7 +296,7 @@ fn parse_short_flags(
|
||||
error = error.or_else(|| {
|
||||
Some(ParseError::UnknownFlag(
|
||||
sig.name.clone(),
|
||||
format!("-{}", String::from_utf8_lossy(contents).to_string()),
|
||||
format!("-{}", String::from_utf8_lossy(contents)),
|
||||
*first,
|
||||
))
|
||||
});
|
||||
|
Reference in New Issue
Block a user