From b3433ebf2784aba79041b60f46159ef46dbe10d9 Mon Sep 17 00:00:00 2001 From: Tamo Date: Thu, 26 Sep 2024 10:50:46 +0200 Subject: [PATCH 1/2] make the warning output errors in the ci --- .github/workflows/rust.yml | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/.github/workflows/rust.yml b/.github/workflows/rust.yml index 02ea113f..97c465af 100644 --- a/.github/workflows/rust.yml +++ b/.github/workflows/rust.yml @@ -6,6 +6,11 @@ on: pull_request: branches: ['main'] +env: + CARGO_TERM_COLOR: always + RUST_BACKTRACE: 1 + RUSTFLAGS: "-D warnings" + jobs: test: runs-on: ${{ matrix.os }} From 2dddeb1cc6ef0a86d44d88d84c4037b6bc23a2d6 Mon Sep 17 00:00:00 2001 From: Tamo Date: Thu, 26 Sep 2024 10:55:13 +0200 Subject: [PATCH 2/2] makes clippy happy --- src/unaligned_vector/f32.rs | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/unaligned_vector/f32.rs b/src/unaligned_vector/f32.rs index 72a967fb..aa078dea 100644 --- a/src/unaligned_vector/f32.rs +++ b/src/unaligned_vector/f32.rs @@ -14,7 +14,7 @@ impl UnalignedVectorCodec for f32 { let rem = bytes.len() % size_of::(); if rem == 0 { // safety: `UnalignedF32Slice` is transparent - Ok(Cow::Borrowed(unsafe { transmute(bytes) })) + Ok(Cow::Borrowed(unsafe { transmute::<&[u8], &UnalignedVector>(bytes) })) } else { Err(SizeMismatch { vector_codec: "f32", rem }) }