Skip to content

Commit

Permalink
Fix clippy lint: unnecessary mut
Browse files Browse the repository at this point in the history
  • Loading branch information
FlareFlo committed Nov 16, 2024
1 parent ca011ce commit c03a46e
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/color.rs
Original file line number Diff line number Diff line change
Expand Up @@ -406,7 +406,7 @@ impl FromPrimitive<f32> for u8 {

impl FromPrimitive<f32> for u16 {
fn from_primitive(float: f32) -> Self {
let mut inner = (float.clamp(0.0, 1.0) * u16::MAX as f32).round();
let inner = (float.clamp(0.0, 1.0) * u16::MAX as f32).round();
NumCast::from(sanitize_nan(inner)).unwrap()
}
}
Expand Down

0 comments on commit c03a46e

Please sign in to comment.