mirror of
https://github.com/nushell/nushell.git
synced 2024-12-23 15:39:06 +01:00
Fix lints
This commit is contained in:
parent
0b15da64c5
commit
5cac3d1135
@ -5,7 +5,7 @@ crate mod registry;
|
|||||||
|
|
||||||
use crate::errors::ShellError;
|
use crate::errors::ShellError;
|
||||||
|
|
||||||
crate use hir::baseline_parse_tokens::{baseline_parse_tokens, trace_remaining};
|
crate use hir::baseline_parse_tokens::baseline_parse_tokens;
|
||||||
crate use parse::call_node::CallNode;
|
crate use parse::call_node::CallNode;
|
||||||
crate use parse::files::Files;
|
crate use parse::files::Files;
|
||||||
crate use parse::flag::Flag;
|
crate use parse::flag::Flag;
|
||||||
|
@ -6,7 +6,6 @@ use crate::parser::{
|
|||||||
};
|
};
|
||||||
use crate::{SpannedItem, Text};
|
use crate::{SpannedItem, Text};
|
||||||
use derive_new::new;
|
use derive_new::new;
|
||||||
use log::trace;
|
|
||||||
|
|
||||||
pub fn baseline_parse_tokens(
|
pub fn baseline_parse_tokens(
|
||||||
token_nodes: &mut TokensIterator<'_>,
|
token_nodes: &mut TokensIterator<'_>,
|
||||||
@ -332,16 +331,3 @@ impl Iterator for TokensIterator<'a> {
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
pub fn trace_remaining(desc: &'static str, tail: hir::TokensIterator<'a>, source: &Text) {
|
|
||||||
trace!(
|
|
||||||
"{} = {:?}",
|
|
||||||
desc,
|
|
||||||
itertools::join(
|
|
||||||
tail.debug_remaining()
|
|
||||||
.iter()
|
|
||||||
.map(|i| format!("%{:?}%", i.debug(source))),
|
|
||||||
" "
|
|
||||||
)
|
|
||||||
);
|
|
||||||
}
|
|
||||||
|
@ -70,7 +70,7 @@ impl fmt::Debug for DebugTokenNode<'a> {
|
|||||||
}
|
}
|
||||||
)
|
)
|
||||||
}
|
}
|
||||||
TokenNode::Pipeline(s) => write!(f, "<todo:pipeline>"),
|
TokenNode::Pipeline(_) => write!(f, "<todo:pipeline>"),
|
||||||
TokenNode::Error(s) => write!(f, "<error> for {:?}", s.span().slice(self.source)),
|
TokenNode::Error(s) => write!(f, "<error> for {:?}", s.span().slice(self.source)),
|
||||||
rest => write!(f, "{}", rest.span().slice(self.source)),
|
rest => write!(f, "{}", rest.span().slice(self.source)),
|
||||||
}
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user