From 26f482d268f6aa2d341548a25a8030c5f5d8eb6f Mon Sep 17 00:00:00 2001 From: Kevin Reid Date: Fri, 27 Dec 2024 13:01:34 -0800 Subject: [PATCH] Lint: Add recommended parentheses. --- all-is-cubes-base/src/math/octant.rs | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/all-is-cubes-base/src/math/octant.rs b/all-is-cubes-base/src/math/octant.rs index 348eca406..a0c0f18c5 100644 --- a/all-is-cubes-base/src/math/octant.rs +++ b/all-is-cubes-base/src/math/octant.rs @@ -113,8 +113,8 @@ impl Octant { /// Ties due to zero components are broken in the positive direction. #[inline] pub fn from_vector(vector: FreeVector) -> Self { - let index = u8::from(vector.x >= 0.) << 2 - | u8::from(vector.y >= 0.) << 1 + let index = (u8::from(vector.x >= 0.) << 2) + | (u8::from(vector.y >= 0.) << 1) | u8::from(vector.z >= 0.); Self::from_zmaj_index(index) }