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

[0.2] Fix usage with rustc-dep-of-std #4167

Merged
merged 3 commits into from
Nov 28, 2024

Conversation

tgross35
Copy link
Contributor

Backport #4158

Since [1] we use derive macros rather than manually implementing `Clone`
and `Copy`. However, this caused the build in `std` to start failing
since the `core` prelude is not available. This provides the derive
macros as well as `derive` itself.

Resolve this by using complete paths. Additionally allow
`internal_features` to suppress the warning using `link_cfg`, and change
to using global paths for all uses of `core`.

Link: rust-lang#4038 [1]

(backport <rust-lang#4158>)
(cherry picked from commit d69ad56)
Add a test that the crate builds correctly with the configuration that
is used in `std`.

(backport <rust-lang#4158>)
(cherry picked from commit 9839a9a)
@rustbot
Copy link
Collaborator

rustbot commented Nov 28, 2024

r? @JohnTitor

rustbot has assigned @JohnTitor.
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

This combination raises an error suggesting `&raw mut errno`. This was
removed in 1.0, but allow the lint on 0.2 for now.
@tgross35 tgross35 added this pull request to the merge queue Nov 28, 2024
Merged via the queue into rust-lang:libc-0.2 with commit 7cbac14 Nov 28, 2024
45 checks passed
@tgross35 tgross35 deleted the backport-fix-rustc-dep-of-std branch November 29, 2024 09:30
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