Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
33 changes: 30 additions & 3 deletions .github/workflows/build.yml
Original file line number Diff line number Diff line change
Expand Up @@ -48,7 +48,16 @@ jobs:
components: miri

- name: Run miri
run: MIRIFLAGS=-Zmiri-ignore-leaks cargo miri test --features="alloc,defmt,mpmc_large,portable-atomic-critical-section,serde,ufmt,bytes,zeroize,embedded-io-v0.7"
run: >
MIRIFLAGS=-Zmiri-ignore-leaks cargo miri test --features="alloc,
defmt,
mpmc_large,
portable-atomic-critical-section,
serde,
ufmt,
bytes,
zeroize,
embedded-io-v0.7"

# Run cargo test
test:
Expand Down Expand Up @@ -84,7 +93,17 @@ jobs:
toolchain: stable

- name: Run cargo test
run: cargo test --features="alloc,defmt,mpmc_large,portable-atomic-critical-section,serde,ufmt,bytes,zeroize,embedded-io-v0.7"
run: >
cargo test --features="
alloc,
defmt,
mpmc_large,
portable-atomic-critical-section,
serde,
ufmt,
bytes,
zeroize,
embedded-io-v0.7"

# Run cargo fmt --check
style:
Expand Down Expand Up @@ -113,7 +132,15 @@ jobs:
with:
components: clippy
targets: i686-unknown-linux-musl
- run: cargo clippy --all --target i686-unknown-linux-musl --all-targets
- run: >
cargo clippy --all --target i686-unknown-linux-musl --all-targets --features "alloc,
defmt,
portable-atomic-critical-section,
serde,
ufmt,
bytes,
zeroize,
embedded-io-v0.7"

# Compilation check
check:
Expand Down
3 changes: 3 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -13,6 +13,9 @@ and this project adheres to [Semantic Versioning](http://semver.org/).
- Added `retain_back` (aka `truncate_front`) to `Deque`
- Fixed unsoundness in `Vec::IntoIter::drop` and `HistoryBuf::write`in the context of panicking drop implementations.
- Added `push_mut` to `Vec`.
- Fixed unsoundness in `IndexMap:insert`.
- Limited max size of `IndexMap` to u16::MAX + 1.
The implementation for sizes higher than u16::MAX were unsound anyway.

## [v0.9.3] 2025-04-15

Expand Down
12 changes: 6 additions & 6 deletions src/de.rs
Original file line number Diff line number Diff line change
Expand Up @@ -43,7 +43,7 @@ where

while let Some(value) = seq.next_element()? {
if values.push(value).is_err() {
return Err(A::Error::invalid_length(values.capacity() + 1, &self))?;
return Err(A::Error::invalid_length(values.capacity() + 1, &self));
}
}

Expand Down Expand Up @@ -84,7 +84,7 @@ where

while let Some(value) = seq.next_element()? {
if values.insert(value).is_err() {
return Err(A::Error::invalid_length(values.capacity() + 1, &self))?;
return Err(A::Error::invalid_length(values.capacity() + 1, &self));
}
}

Expand Down Expand Up @@ -124,7 +124,7 @@ where

while let Some(value) = seq.next_element()? {
if values.push(value).is_err() {
return Err(A::Error::invalid_length(values.capacity() + 1, &self))?;
return Err(A::Error::invalid_length(values.capacity() + 1, &self));
}
}

Expand Down Expand Up @@ -163,7 +163,7 @@ where

while let Some(value) = seq.next_element()? {
if values.push_back(value).is_err() {
return Err(A::Error::invalid_length(values.capacity() + 1, &self))?;
return Err(A::Error::invalid_length(values.capacity() + 1, &self));
}
}

Expand Down Expand Up @@ -245,7 +245,7 @@ where

while let Some((key, value)) = map.next_entry()? {
if values.insert(key, value).is_err() {
return Err(A::Error::invalid_length(values.capacity() + 1, &self))?;
return Err(A::Error::invalid_length(values.capacity() + 1, &self));
}
}

Expand Down Expand Up @@ -286,7 +286,7 @@ where

while let Some((key, value)) = map.next_entry()? {
if values.insert(key, value).is_err() {
return Err(A::Error::invalid_length(values.capacity() + 1, &self))?;
return Err(A::Error::invalid_length(values.capacity() + 1, &self));
}
}

Expand Down
Loading
Loading