-
Notifications
You must be signed in to change notification settings - Fork 36
Heapless release 091 #200
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Heapless release 091 #200
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Great job @sgued ! I can only offer nitpicks. :)
|
||
# Heapless `0.9.1` released | ||
|
||
Almost 2 years after the last release, the [heapless](https://github.com/rust-embedded/heapless) crate has a new release. The first attempt at a `0.9.0` release was yanked due to including more breaking changes than intended. This has been fixed, and `0.9.1` has been released today. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Sorry for the nitpick but could we please keep all the lines under 100 chars and break lines on the word boundary based on this limit rather than for starting a new sentence (in the same paragraph)? 🙏
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Existing entries don't do that. My editor (helix) handles word wrapping very well, I don't really want to do this manually and would rather focus on the content than the formatting. Markdown and Zola are here to handle the formatting.
content/2025-08-20-heapless-091.md
Outdated
# The `LenType` optimization | ||
|
||
Most often, buffers in embedded applications will not contain a huge number of items. | ||
Until `0.9.1` the capacity of the `heapless` data structures were almost always stored as a `usize`, which can often encode much more values than necessary. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
capacity -> capacities
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I'm not sure. Capacities plural seems weird. I read it as the capacity of each of heapless data structures, even without the "each". But I'm not a native speaker either.
content/2025-08-20-heapless-091.md
Outdated
|
||
If you are seriously constrained by memory, a `Vec<T, 28>` (equivalent to `Vec<T, 28, usize>`) can become a `Vec<T, 28, u8>`, saving up to 7 bytes per `Vec`. This is not much, but in very small microcontrollers, it can make the difference between a program that uses all the memory available and one that just fits. | ||
|
||
This release was made possible by [@sgued] and [@zeenix] joining the embedded working group as part of the libs team to help maintain `heapless`. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thanks to attributing. 🙏 This should probably either go under another heading (e.g "Contributors") or separated from the previous paragraph through a ruler (---
).
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Made it its own section and credited other contributors too.
ad703cd
to
55849f7
Compare
2478737
to
136e4d3
Compare
136e4d3
to
96a881e
Compare
Can we merge this this evening? It'd be nice to have it in tomorrow's this week in Rust |
@zeenix tell me if you would add anything else.
Once OK I'll release heapless and I'll add this to This Week In Rust.
I've only tested it with an up to date version of Zola so #199 should probably be merged first.