gioser

tawasuyu/taffy

A high performance rust-powered UI layout library

Rust 497HTML 254C 19JavaScript 81329 Definitions

Allow `clippy::transmute_float_to_int` in MSRV compat functions (#799)

This lint suggests that we use the newly stabilised f32::to_bits
and f32::from_bits functions. But we are explicitly avoiding those
for MSRV reasons.

Signed-off-by: Nico Burns <nico@nicoburns.com>

ce089b3093bafba9d4e104f87b2592a28b880d2a · by Nico Burns · (1 year ago) · parent 861a9dab7 · browse the tree at this commit

Semantic delta

No definition changed: this change is text, documentation or data.

1 files · +1 −0

diff --git a/src/style/compact_length.rs b/src/style/compact_length.rs
index fa32308a4..cca0d48b6 100644
--- a/src/style/compact_length.rs
+++ b/src/style/compact_length.rs
@@ -295,6 +295,7 @@ impl TaffyFitContent for CompactLength {
 /// here we can reduce MSRV from 1.83 all the way down to 1.65 while retaining const constructors.
 mod compat {
     #![allow(unsafe_code)]
+    #![allow(clippy::transmute_float_to_int)]
 
     /// Raw transmutation from `f32` to `u32`.
     pub const fn f32_to_bits(val: f32) -> u32 {