fix(tvix/eval): fix current clippy warnings

It's been a while since the last time, so quite a lot of stuff has
accumulated here.

Change-Id: I0762827c197b30a917ff470fd8ae8f220f6ba247
Reviewed-on: https://cl.tvl.fyi/c/depot/+/7597
Reviewed-by: grfn <grfn@gws.fyi>
Autosubmit: tazjin <tazjin@tvl.su>
Tested-by: BuildkiteCI
This commit is contained in:
Vincent Ambo 2022-12-20 17:22:56 +03:00 committed by clbot
parent 67d508f2ec
commit 71174f6626
17 changed files with 69 additions and 108 deletions

View file

@ -804,7 +804,7 @@ impl Compiler<'_> {
}
if let Some(ast::InterpolPart::Literal(lit)) = parts.pop() {
return Some(SmolStr::new(&lit));
return Some(SmolStr::new(lit));
}
None
@ -812,7 +812,6 @@ impl Compiler<'_> {
/// Convert the provided `ast::Attr` into a statically known string if
/// possible.
// TODO(tazjin): these should probably be SmolStr
fn expr_static_attr_str(&self, node: &ast::Attr) -> Option<SmolStr> {
match node {
ast::Attr::Ident(ident) => Some(ident.ident_token().unwrap().text().into()),