refactor: modularize lib.rs - #457
Closed
alejandro-vaz wants to merge 6 commits into
Closed
alejandro-vaz wants to merge 6 commits into
alejandro-vaz wants to merge 6 commits into
Conversation
* Make `collect_from_iter` use less iterations under miri * Optimize `pop` implementation * Optimize `retain_mut` implementation
alejandro-vaz
force-pushed
the
modrefactor
branch
from
August 27, 2026 13:38
a77103b to
e68ff6f
Compare
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.
this is the preliminary refactor of #427. it adds most of the minor modules, leaving the major ones to be modularized with more care
scope of this PR
this PR splits
lib.rsinto:bytes.rs=> for the bytes featureerrors.rs=> for the error typemacros.rs=> for the deprecated smallvec macrosmallocsizeof.rs=> for the malloc_size_of featurereferences.rs=> Deref, borrow, asrefserde.rs=> serialize, deserializetaggedlen.rs=> for the lengthlib.rsstill contains code that has not been modularized yet, thus this PR is part of #427 but doesn't close it yetother changes
is_zst::<T>()helper which was a simple equality checkrustfmt.toml, along with some other minor formatting constraints