Skip to content
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

Add support for allocator_api on stable #30

Merged
merged 7 commits into from
Apr 13, 2024
Merged

Conversation

jess-sol
Copy link
Contributor

This allows the allocator api to be used in Rust stable. The allocator-api2 crate also optionally implements serde support for their re-implementations of Vec, Box, etc. Which can be really helpful when trying to serialize/deserialize data that's using a custom allocator.

In order not to break things, if the allocator feature flag is set, it'll take precedence. The allocator_api2 crate will only be used if default_features is false and allocator_api2 is added.

Add optional allocator-api2 package which provides the allocator api in Rust stable.
@SFBdragon
Copy link
Owner

Looks good! Thanks for the PR. I'm aiming to merge this soon and publish a new version a bit later today once I have time to add the new feature configuration to the testing scripts and making sure everything is in order.

The features configuration looks congruent with the rest at a glance, thanks. [I don't like the current default feature configuration (unstable by default, which made more sense when I was only targeting systems/embedded use cases). I'll change it if I manage to justify a V5.]

@SFBdragon
Copy link
Owner

Alright, besides a version bump I think everything is in order now. Sorry about all the noise.

The new stable Rust example needed to be put in its own package due to the nightly-by-default config, and I felt that it was a good opportunity to turn the repo into a proper workspace.

Once again, thanks for the contribution!

@SFBdragon SFBdragon merged commit 8579035 into SFBdragon:master Apr 13, 2024
3 checks passed
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