summaryrefslogtreecommitdiff
path: root/ecs
diff options
context:
space:
mode:
authorHampusM <hampus@hampusmat.com>2025-08-22 17:31:40 +0200
committerHampusM <hampus@hampusmat.com>2025-08-22 17:31:40 +0200
commite766f6581c2ca8a8963baed11ad29d6e67a0a8a0 (patch)
tree1239890300745a87ddbfcd1aefd8c8127be73523 /ecs
parentab8750c9d29b59f02f2e807de3307a48225d6087 (diff)
refactor(ecs): fix mismatched_lifetime_syntaxes warnings
Diffstat (limited to 'ecs')
-rw-r--r--ecs/src/component/storage/archetype.rs2
-rw-r--r--ecs/src/component/storage/graph.rs2
-rw-r--r--ecs/src/lib.rs4
-rw-r--r--ecs/src/lock.rs4
4 files changed, 7 insertions, 5 deletions
diff --git a/ecs/src/component/storage/archetype.rs b/ecs/src/component/storage/archetype.rs
index a88e0e8..8e1ff05 100644
--- a/ecs/src/component/storage/archetype.rs
+++ b/ecs/src/component/storage/archetype.rs
@@ -122,7 +122,7 @@ impl Archetype
pub fn get_matching_component_indices(
&self,
component_id: Uid,
- ) -> MatchingComponentIter
+ ) -> MatchingComponentIter<'_>
{
assert!(
component_id.kind() == UidKind::Component
diff --git a/ecs/src/component/storage/graph.rs b/ecs/src/component/storage/graph.rs
index 29fa937..76200f9 100644
--- a/ecs/src/component/storage/graph.rs
+++ b/ecs/src/component/storage/graph.rs
@@ -80,7 +80,7 @@ impl Graph
pub fn dfs_archetype_add_edges(
&self,
archetype_id: ArchetypeId,
- ) -> Option<ArchetypeAddEdgeDfsIter>
+ ) -> Option<ArchetypeAddEdgeDfsIter<'_>>
{
let node = self.get_node_by_id(archetype_id)?;
diff --git a/ecs/src/lib.rs b/ecs/src/lib.rs
index 2b4302a..302fe55 100644
--- a/ecs/src/lib.rs
+++ b/ecs/src/lib.rs
@@ -193,7 +193,9 @@ impl World
extension.collect(extension_collector);
}
- pub fn query<FieldTerms, FieldlessTerms>(&self) -> Query<FieldTerms, FieldlessTerms>
+ pub fn query<FieldTerms, FieldlessTerms>(
+ &self,
+ ) -> Query<'_, FieldTerms, FieldlessTerms>
where
FieldTerms: QueryTermWithFieldTuple,
FieldlessTerms: QueryTermWithoutFieldTuple,
diff --git a/ecs/src/lock.rs b/ecs/src/lock.rs
index d21b697..abdf995 100644
--- a/ecs/src/lock.rs
+++ b/ecs/src/lock.rs
@@ -30,7 +30,7 @@ impl<Value> Lock<Value>
///
/// # Errors
/// Returns `Err` if unavailable (A mutable handle is hold).
- pub fn read_nonblock(&self) -> Result<ReadGuard<Value>, Error>
+ pub fn read_nonblock(&self) -> Result<ReadGuard<'_, Value>, Error>
{
let guard = self.inner.try_read().ok_or(Error::ReadUnavailable)?;
@@ -46,7 +46,7 @@ impl<Value> Lock<Value>
///
/// # Errors
/// Returns `Err` if unavailable (A mutable or immutable handle is hold).
- pub fn write_nonblock(&self) -> Result<WriteGuard<Value>, Error>
+ pub fn write_nonblock(&self) -> Result<WriteGuard<'_, Value>, Error>
{
let guard = self.inner.try_write().ok_or(Error::WriteUnavailable)?;