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

Implement core::error::Error on Rust 1.81+ #747

Merged
merged 1 commit into from
Dec 4, 2024

Conversation

alexcrichton
Copy link
Contributor

This commit updates when the Error trait is implemented to account for how in Rust 1.81-and-prior the Error trait is always available, even in core. This is currently done with detection at build-time of the current Rust compiler version because the MSRV for this crate is below 1.81. In the future when the MSRV is increased, however, the build script can be deleted.

This commit updates when the `Error` trait is implemented to account for
how in Rust 1.81-and-prior the `Error` trait is always available, even
in `core`. This is currently done with detection at build-time of the
current Rust compiler version because the MSRV for this crate is below
1.81. In the future when the MSRV is increased, however, the build
script can be deleted.
build.rs Show resolved Hide resolved
Copy link
Contributor

@philipc philipc left a comment

Choose a reason for hiding this comment

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

Thanks!

println!("cargo:rustc-cfg=core_error");
}
if minor >= 80 {
println!("cargo:rustc-check-cfg=cfg(core_error)");
Copy link
Contributor

Choose a reason for hiding this comment

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

@philipc philipc merged commit 2b9db57 into gimli-rs:master Dec 4, 2024
10 checks passed
@alexcrichton alexcrichton deleted the impl-core-error branch December 4, 2024 15:31
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.

3 participants