Skip to content

Commit

Permalink
Merge pull request #97 from meilisearch/make-the-warning-output-errors
Browse files Browse the repository at this point in the history
Make the warning output errors in the ci
  • Loading branch information
Kerollmops authored Sep 26, 2024
2 parents a72d20d + 2dddeb1 commit 13985ba
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 1 deletion.
5 changes: 5 additions & 0 deletions .github/workflows/rust.yml
Original file line number Diff line number Diff line change
Expand Up @@ -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 }}
Expand Down
2 changes: 1 addition & 1 deletion src/unaligned_vector/f32.rs
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@ impl UnalignedVectorCodec for f32 {
let rem = bytes.len() % size_of::<f32>();
if rem == 0 {
// safety: `UnalignedF32Slice` is transparent
Ok(Cow::Borrowed(unsafe { transmute(bytes) }))
Ok(Cow::Borrowed(unsafe { transmute::<&[u8], &UnalignedVector<f32>>(bytes) }))
} else {
Err(SizeMismatch { vector_codec: "f32", rem })
}
Expand Down

0 comments on commit 13985ba

Please sign in to comment.