Skip to content

Commit

Permalink
feat/container: fix clippy 0.1.67
Browse files Browse the repository at this point in the history
  • Loading branch information
topenkoff committed Jan 28, 2023
1 parent 79915ad commit 8dbd549
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 3 deletions.
2 changes: 1 addition & 1 deletion hitbox-derive/src/cacheable_macro.rs
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@ use crate::container::Container;
/// are used if macros of the same name are not used.
pub fn impl_macro(ast: &syn::DeriveInput) -> syn::Result<TokenStream> {
let name = &ast.ident;
let message_type = format!("{}", name);
let message_type = format!("{name}");
let attrs = Container::from_ast(ast)?;

let cache_key_implement = quote! {
Expand Down
4 changes: 2 additions & 2 deletions hitbox-derive/src/container.rs
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@ fn parse_lit_to_u32(lit: &syn::Lit, attr_name: &str) -> syn::Result<u32> {
.map_err(|e| syn::Error::new_spanned(lit, e)),
_ => Err(syn::Error::new_spanned(
lit,
format!("Expected hitbox {} attribute should be u32", attr_name),
format!("Expected hitbox {attr_name} attribute should be u32"),
)),
}
}
Expand Down Expand Up @@ -71,7 +71,7 @@ impl Container {
let path = m.path().into_token_stream().to_string().replace(' ', "");
return Err(syn::Error::new_spanned(
m.path(),
format!("Unknown hitbox container attribute `{}`", path),
format!("Unknown hitbox container attribute `{path}`"),
));
}

Expand Down

0 comments on commit 8dbd549

Please sign in to comment.