Skip to content

chore(doc): update zst doc - #96

Merged
emilio merged 2 commits into
mozilla:mainfrom
Baptistemontan:update_zst_docs
Sep 16, 2026
Merged

emilio merged 2 commits into
mozilla:mainfrom
Baptistemontan:update_zst_docs

Conversation

@Baptistemontan

@Baptistemontan Baptistemontan commented Sep 16, 2026

Copy link
Copy Markdown
Contributor

Some docs about ZSTs are now outdated after #92 and #94

Comment thread src/lib.rs Outdated
/// lengths. As such, we cannot provide the same guarantees about ThinVecs
/// of ZSTs not allocating. However the allocation never needs to be resized
/// to add more ZSTs, since the underlying array is still length 0.
/// **NOTE**: like `Vec`, `ThinVec` does'nt allocate for ZSTs and store the length inline,

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

nit: does'nt -> doesn't

Also store -> stores

Comment thread src/lib.rs Outdated
//! * `ThinVec::new()` doesn't allocate (it points to a statically allocated singleton)
//! * reallocation can be done in place
//! * `size_of::<ThinVec<T>>()` == `size_of::<Option<ThinVec<T>>>()`
//! * Does'nt allocate for Zero Sized Types (e.g. `ThinVec<()>`), but only without the "gecko-ffi" feature.

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Same, Does'nt -> Doesn't

@Baptistemontan

Copy link
Copy Markdown
Contributor Author

yeah I'm not an english native, still make those kind of typos sometimes

@emilio
emilio merged commit 261cb50 into mozilla:main Sep 16, 2026
5 checks passed
@Baptistemontan
Baptistemontan deleted the update_zst_docs branch September 16, 2026 22:43
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants