Decode into an uninitialized byte slice#63
Merged
Conversation
a10y
reviewed
Dec 30, 2024
Comment on lines
+255
to
+257
| pub fn decompressed_capacity(&self, compressed: &[u8]) -> usize { | ||
| size_of::<Symbol>() * (compressed.len() + 1) | ||
| } |
Contributor
There was a problem hiding this comment.
we should call this max_decompression_capacity. it's an upper-bound since symbols need not be 8 bytes (and most of them time they'll be <= 3bytes)
Contributor
Author
There was a problem hiding this comment.
Yep fair, although the check is that the slice must be == this capacity. We could make it <=, but would require a bounds check inside each iteration which feels... slow
a10y
approved these changes
Dec 30, 2024
Merged
gatesn
pushed a commit
that referenced
this pull request
Dec 30, 2024
## 🤖 New release * `fsst-rs`: 0.4.3 -> 0.4.4 (✓ API compatible changes) <details><summary><i><b>Changelog</b></i></summary><p> <blockquote> ## [0.4.4](v0.4.3...v0.4.4) - 2024-12-30 ### Added - add dbtext decompression benchmark (#44) ### Other - Decode into an uninitialized byte slice ([#63](#63)) - *(deps)* lock file maintenance (#62) - *(deps)* lock file maintenance (#60) - *(deps)* lock file maintenance (#59) - *(deps)* update mozilla-actions/sccache-action action to v0.0.7 (#58) - *(deps)* lock file maintenance (#57) - *(deps)* lock file maintenance (#56) - *(deps)* lock file maintenance (#55) - *(deps)* lock file maintenance (#54) - *(deps)* lock file maintenance (#53) - *(deps)* lock file maintenance (#50) - *(deps)* lock file maintenance (#49) - *(deps)* lock file maintenance (#47) - *(deps)* lock file maintenance (#46) </blockquote> </p></details> --- This PR was generated with [release-plz](https://github.com/release-plz/release-plz/). Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>
a1412744807
added a commit
to a1412744807/rs-fsst
that referenced
this pull request
Oct 27, 2025
## 🤖 New release * `fsst-rs`: 0.4.3 -> 0.4.4 (✓ API compatible changes) <details><summary><i><b>Changelog</b></i></summary><p> <blockquote> ## [0.4.4](spiraldb/fsst@v0.4.3...v0.4.4) - 2024-12-30 ### Added - add dbtext decompression benchmark (#44) ### Other - Decode into an uninitialized byte slice ([#63](spiraldb/fsst#63)) - *(deps)* lock file maintenance (#62) - *(deps)* lock file maintenance (#60) - *(deps)* lock file maintenance (#59) - *(deps)* update mozilla-actions/sccache-action action to v0.0.7 (#58) - *(deps)* lock file maintenance (#57) - *(deps)* lock file maintenance (#56) - *(deps)* lock file maintenance (#55) - *(deps)* lock file maintenance (#54) - *(deps)* lock file maintenance (#53) - *(deps)* lock file maintenance (#50) - *(deps)* lock file maintenance (#49) - *(deps)* lock file maintenance (#47) - *(deps)* lock file maintenance (#46) </blockquote> </p></details> --- This PR was generated with [release-plz](https://github.com/release-plz/release-plz/). Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>
Goodbai-1206
added a commit
to Goodbai-1206/fsst-rs
that referenced
this pull request
Oct 29, 2025
## 🤖 New release * `fsst-rs`: 0.4.3 -> 0.4.4 (✓ API compatible changes) <details><summary><i><b>Changelog</b></i></summary><p> <blockquote> ## [0.4.4](spiraldb/fsst@v0.4.3...v0.4.4) - 2024-12-30 ### Added - add dbtext decompression benchmark (#44) ### Other - Decode into an uninitialized byte slice ([#63](spiraldb/fsst#63)) - *(deps)* lock file maintenance (#62) - *(deps)* lock file maintenance (#60) - *(deps)* lock file maintenance (#59) - *(deps)* update mozilla-actions/sccache-action action to v0.0.7 (#58) - *(deps)* lock file maintenance (#57) - *(deps)* lock file maintenance (#56) - *(deps)* lock file maintenance (#55) - *(deps)* lock file maintenance (#54) - *(deps)* lock file maintenance (#53) - *(deps)* lock file maintenance (#50) - *(deps)* lock file maintenance (#49) - *(deps)* lock file maintenance (#47) - *(deps)* lock file maintenance (#46) </blockquote> </p></details> --- This PR was generated with [release-plz](https://github.com/release-plz/release-plz/). Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>
akkjs887
added a commit
to akkjs887/rt-rsst
that referenced
this pull request
Oct 29, 2025
## 🤖 New release * `fsst-rs`: 0.4.3 -> 0.4.4 (✓ API compatible changes) <details><summary><i><b>Changelog</b></i></summary><p> <blockquote> ## [0.4.4](spiraldb/fsst@v0.4.3...v0.4.4) - 2024-12-30 ### Added - add dbtext decompression benchmark (#44) ### Other - Decode into an uninitialized byte slice ([#63](spiraldb/fsst#63)) - *(deps)* lock file maintenance (#62) - *(deps)* lock file maintenance (#60) - *(deps)* lock file maintenance (#59) - *(deps)* update mozilla-actions/sccache-action action to v0.0.7 (#58) - *(deps)* lock file maintenance (#57) - *(deps)* lock file maintenance (#56) - *(deps)* lock file maintenance (#55) - *(deps)* lock file maintenance (#54) - *(deps)* lock file maintenance (#53) - *(deps)* lock file maintenance (#50) - *(deps)* lock file maintenance (#49) - *(deps)* lock file maintenance (#47) - *(deps)* lock file maintenance (#46) </blockquote> </p></details> --- This PR was generated with [release-plz](https://github.com/release-plz/release-plz/). Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>
yelirekhmon
added a commit
to yelirekhmon/fstrs
that referenced
this pull request
Oct 30, 2025
## 🤖 New release * `fsst-rs`: 0.4.3 -> 0.4.4 (✓ API compatible changes) <details><summary><i><b>Changelog</b></i></summary><p> <blockquote> ## [0.4.4](spiraldb/fsst@v0.4.3...v0.4.4) - 2024-12-30 ### Added - add dbtext decompression benchmark (#44) ### Other - Decode into an uninitialized byte slice ([#63](spiraldb/fsst#63)) - *(deps)* lock file maintenance (#62) - *(deps)* lock file maintenance (#60) - *(deps)* lock file maintenance (#59) - *(deps)* update mozilla-actions/sccache-action action to v0.0.7 (#58) - *(deps)* lock file maintenance (#57) - *(deps)* lock file maintenance (#56) - *(deps)* lock file maintenance (#55) - *(deps)* lock file maintenance (#54) - *(deps)* lock file maintenance (#53) - *(deps)* lock file maintenance (#50) - *(deps)* lock file maintenance (#49) - *(deps)* lock file maintenance (#47) - *(deps)* lock file maintenance (#46) </blockquote> </p></details> --- This PR was generated with [release-plz](https://github.com/release-plz/release-plz/). Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Fixes #61