diff options
Diffstat (limited to 'ecs/src/sole.rs')
-rw-r--r-- | ecs/src/sole.rs | 24 |
1 files changed, 1 insertions, 23 deletions
diff --git a/ecs/src/sole.rs b/ecs/src/sole.rs index 4a4f3af..084a06b 100644 --- a/ecs/src/sole.rs +++ b/ecs/src/sole.rs @@ -1,4 +1,4 @@ -use std::any::{type_name, Any, TypeId}; +use std::any::{type_name, Any}; use std::fmt::Debug; use std::marker::PhantomData; use std::ops::{Deref, DerefMut}; @@ -113,23 +113,6 @@ where Self::new(sole) } - - fn is_compatible<Other: SystemParam<'world>>() -> bool - { - let other_comparable = Other::get_comparable(); - - let Some(comparable) = other_comparable.downcast_ref::<Comparable>() else { - // The other system param is not Single - return true; - }; - - TypeId::of::<SoleT>() != comparable.sole_type_id - } - - fn get_comparable() -> Box<dyn Any> - { - Box::new(Comparable { sole_type_id: TypeId::of::<SoleT>() }) - } } impl<'world, SoleT> Deref for Single<'world, SoleT> @@ -201,8 +184,3 @@ where Single::new(&self.sole) } } - -struct Comparable -{ - sole_type_id: TypeId, -} |