Skip to content

Commit

Permalink
Merge pull request #56 from MrGVSV/fix-clippy
Browse files Browse the repository at this point in the history
Fix clippy and formatting
  • Loading branch information
MrGVSV authored Sep 9, 2023
2 parents 7a00183 + 0f5f8f5 commit eb61b9d
Show file tree
Hide file tree
Showing 2 changed files with 8 additions and 1 deletion.
5 changes: 5 additions & 0 deletions bevy_proto_backend/src/impls/macros.rs
Original file line number Diff line number Diff line change
Expand Up @@ -29,6 +29,7 @@ macro_rules! from {

impl From<Input> for $real {
fn from(value: Input) -> Self {
#[allow(clippy::redundant_closure_call)]
$body(value)
}
}
Expand All @@ -49,6 +50,7 @@ macro_rules! from_to {

impl From<Input> for $mock {
fn from(value: Input) -> Self {
#[allow(clippy::redundant_closure_call)]
$body(value)
}
}
Expand All @@ -59,6 +61,7 @@ macro_rules! from_to {

impl From<Input> for $real {
fn from(value: Input) -> Self {
#[allow(clippy::redundant_closure_call)]
$body(value)
}
}
Expand All @@ -78,6 +81,7 @@ macro_rules! from_to_input {
input: Input,
context: &mut $crate::schematics::SchematicContext,
) -> Self {
#[allow(clippy::redundant_closure_call)]
$body(input, context)
}
}
Expand All @@ -91,6 +95,7 @@ macro_rules! from_to_input {
input: Input,
context: &mut $crate::schematics::SchematicContext,
) -> Self {
#[allow(clippy::redundant_closure_call)]
$body(input, context)
}
}
Expand Down
4 changes: 3 additions & 1 deletion bevy_proto_derive/src/schematic/field_attributes.rs
Original file line number Diff line number Diff line change
Expand Up @@ -275,7 +275,9 @@ impl<'a> FieldAttributesBuilder<'a> {
ReplacementType::Asset(AssetConfig::default()),
meta.path.span(),
)?;
let ReplacementType::Asset(config) = &mut self.attrs.replacement_ty else {unreachable!()};
let ReplacementType::Asset(config) = &mut self.attrs.replacement_ty else {
unreachable!()
};
config
};

Expand Down

0 comments on commit eb61b9d

Please sign in to comment.