Skip to content

Add optional zerocopy crate derives#3914

Closed
joshlf wants to merge 1 commit intorust-lang:libc-0.2from
joshlf:zerocopy-feature
Closed

Add optional zerocopy crate derives#3914
joshlf wants to merge 1 commit intorust-lang:libc-0.2from
joshlf:zerocopy-feature

Conversation

@joshlf
Copy link
Contributor

@joshlf joshlf commented Sep 10, 2024

This is not ready for merging until zerocopy publishes a stable 0.8 release (currently it only has 0.8 alpha releases). I'm putting this up now to test out CI and get the ball rolling in case there are fixes required.

@rustbot
Copy link
Collaborator

rustbot commented Sep 10, 2024

r? @tgross35

rustbot has assigned @tgross35.
They will have a look at your PR within the next two weeks and either review your PR or reassign to another reviewer.

Use r? to explicitly pick a reviewer

joshlf added a commit to joshlf/libc that referenced this pull request Sep 14, 2024
This permits `Cargo.toml` to include optional dependencies. On
toolchains earlier than 1.31, the optional dependency syntax is not
supported. With the MSRV at 1.31, any optional dependency may be
supported even if *its* MSRV is higher than *our* MSRV since only users
using a more recent toolchain will enable that dependency.

In particular, this paves the way for adding an optional `zerocopy`
dependency (prototyped in rust-lang#3407 and rust-lang#3914; see also google/zerocopy#557),
which permits many uses of libc to no longer require `unsafe` code.
@joshlf joshlf mentioned this pull request Sep 14, 2024
joshlf added a commit to joshlf/libc that referenced this pull request Sep 14, 2024
This permits `Cargo.toml` to include optional dependencies. On
toolchains earlier than 1.31, the optional dependency syntax is not
supported. With the MSRV at 1.31, any optional dependency may be
supported even if *its* MSRV is higher than *our* MSRV since only users
using a more recent toolchain will enable that dependency.

In particular, this paves the way for adding an optional `zerocopy`
dependency (prototyped in rust-lang#3407 and rust-lang#3914; see also google/zerocopy#557),
which permits many uses of libc to no longer require `unsafe` code.
joshlf added a commit to joshlf/libc that referenced this pull request Sep 14, 2024
This permits `Cargo.toml` to include optional dependencies. On
toolchains earlier than 1.31, the optional dependency syntax is not
supported. With the MSRV at 1.31, any optional dependency may be
supported even if *its* MSRV is higher than *our* MSRV since only users
using a more recent toolchain will enable that dependency.

In particular, this paves the way for adding an optional `zerocopy`
dependency (prototyped in rust-lang#3407 and rust-lang#3914; see also google/zerocopy#557),
which permits many uses of libc to no longer require `unsafe` code.
joshlf added a commit to joshlf/libc that referenced this pull request Sep 14, 2024
This permits `Cargo.toml` to include optional dependencies. On
toolchains earlier than 1.31, the optional dependency syntax is not
supported. With the MSRV at 1.31, any optional dependency may be
supported even if *its* MSRV is higher than *our* MSRV since only users
using a more recent toolchain will enable that dependency.

In particular, this paves the way for adding an optional `zerocopy`
dependency (prototyped in rust-lang#3407 and rust-lang#3914; see also google/zerocopy#557),
which permits many uses of libc to no longer require `unsafe` code.
@tgross35
Copy link
Contributor

As mentioned in #3924 (comment), we can't take on new large features for 0.2. Thanks for the PR, but it is better to focus both author and reviewer effort for such things into something that targets main - it seems like #3407 does that.

@tgross35 tgross35 closed this Sep 17, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants