From 7a7d3a350b22b5555c27debff6fee4fc6100fa38 Mon Sep 17 00:00:00 2001 From: HampusM Date: Tue, 18 Mar 2025 13:21:46 +0100 Subject: refactor(ecs): fix Clippy lints --- ecs/src/query/options.rs | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) (limited to 'ecs/src/query/options.rs') diff --git a/ecs/src/query/options.rs b/ecs/src/query/options.rs index 772d091..6318359 100644 --- a/ecs/src/query/options.rs +++ b/ecs/src/query/options.rs @@ -8,12 +8,12 @@ use crate::EntityComponent; /// Query options. pub trait Options { - fn entity_filter<'component>(components: &'component [EntityComponent]) -> bool; + fn entity_filter(components: &[EntityComponent]) -> bool; } impl Options for () { - fn entity_filter<'component>(_components: &'component [EntityComponent]) -> bool + fn entity_filter(_components: &[EntityComponent]) -> bool { true } @@ -30,10 +30,10 @@ impl Options for With where ComponentT: Component, { - fn entity_filter<'component>(components: &'component [EntityComponent]) -> bool + fn entity_filter(components: &[EntityComponent]) -> bool { let ids_set = components - .into_iter() + .iter() .map(|component| component.id) .collect::>(); @@ -52,7 +52,7 @@ impl Options for Not where OptionsT: Options, { - fn entity_filter<'component>(components: &'component [EntityComponent]) -> bool + fn entity_filter(components: &[EntityComponent]) -> bool { !OptionsT::entity_filter(components) } -- cgit v1.2.3-18-g5258