summaryrefslogtreecommitdiff
path: root/ecs/src/uid.rs
diff options
context:
space:
mode:
authorHampusM <hampus@hampusmat.com>2024-11-11 00:24:27 +0100
committerHampusM <hampus@hampusmat.com>2024-11-11 00:24:27 +0100
commit7c5c87d316df31bfe732872df10eaa1a4b6f3a12 (patch)
treedd8a0f1f3131ba279569899a008c058216c5d1e9 /ecs/src/uid.rs
parent06750934c33a8b1458d60fe8d877bbf29ffda955 (diff)
refactor(ecs): fix clippy lints
Diffstat (limited to 'ecs/src/uid.rs')
-rw-r--r--ecs/src/uid.rs3
1 files changed, 2 insertions, 1 deletions
diff --git a/ecs/src/uid.rs b/ecs/src/uid.rs
index 56d84f9..0e5d88a 100644
--- a/ecs/src/uid.rs
+++ b/ecs/src/uid.rs
@@ -29,10 +29,11 @@ impl Uid
let id_part = NEXT.fetch_add(1, Ordering::Relaxed);
Self {
- inner: ((id_part as u64) << 32) | kind as u64,
+ inner: (u64::from(id_part) << 32) | kind as u64,
}
}
+ #[must_use]
pub fn kind(&self) -> Kind
{
// SAFETY: The kind bits cannot be invalid since they are set using the Kind enum