From 9ef4675ccbd96ecfcf2d93f9eb0439768f967f08 Mon Sep 17 00:00:00 2001 From: HampusM Date: Thu, 29 Feb 2024 22:01:35 +0100 Subject: fix(ecs): make Query Comps generic type bound to ComponentSequence --- ecs/src/lib.rs | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/ecs/src/lib.rs b/ecs/src/lib.rs index 3c59554..a9ef2a4 100644 --- a/ecs/src/lib.rs +++ b/ecs/src/lib.rs @@ -108,12 +108,16 @@ impl Default for World #[derive(Debug)] pub struct Query<'world, Comps> +where + Comps: ComponentSequence, { component_storage: &'world mut ComponentStorage, comps_pd: PhantomData, } impl<'world, Comps> Query<'world, Comps> +where + Comps: ComponentSequence, { fn new(component_storage: &'world mut ComponentStorage) -> Self { -- cgit v1.2.3-18-g5258