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

Minimum Supported Rust Version isn't supported #79

Closed
Michael-F-Bryan opened this issue Sep 26, 2021 · 1 comment
Closed

Minimum Supported Rust Version isn't supported #79

Michael-F-Bryan opened this issue Sep 26, 2021 · 1 comment

Comments

@Michael-F-Bryan
Copy link

Choose one: this is a 🐛 bug report

A number of this crate's dependencies no longer compile on Rust 1.36.0, meaning this crate is no longer usable on Rust 1.36.0.

Expected Behavior

Running cargo 1.36.0 build should pass.

Current Behavior

There are almost certainly more compile errors, but running cargo 1.36.0 build shows that rustc-demangle and memchr no longer work with Rust 1.36.0.

Possible Solution

There are two possible solutions:

  1. Update this crate's MSRV (a breaking change)
  2. Pin the offending crates to a supported version

I don't believe the second solution is feasible because the offending crates are transitive dependencies.

The best solution would be to bump the MSRV and create a new major release. While we're at it, we could use some newer Rust features so there are less breaking changes in the future or take advantage of recent features.

  • Add the #[non_exhaustive] attribute to Metadata so adding extra metadata to a report isn't a breaking change
    • This would require introducing a builder API so people can initialize Metadata themselves

Context

I don't particularly mind because I almost always use nightly or stable Rust, but MSRV is very important to some people and we should try to accommodate them.

Code Sample

$ git checkout ffe447a2c66b41b338edb440470c42050bbc0dd5
$ cargo  1.36.0 test
  ...
error: cannot find macro `matches!` in this scope
   --> /home/michael/.cargo/registry/src/github.com-1ecc6299db9ec823/rustc-demangle-0.1.21/src/v0.rs:700:20
    |
700 |                 if matches!((quote, c), ('\'', '"') | ('"', '\'')) {
    |                    ^^^^^^^

error: aborting due to previous error

error: Could not compile `rustc-demangle`.
warning: build failed, waiting for other jobs to finish...
error[E0658]: naming constants with `_` is unstable
  --> /home/michael/.cargo/registry/src/github.com-1ecc6299db9ec823/memchr-2.4.1/src/memmem/prefilter/fallback.rs:37:1
   |
37 | const _: PrefilterFnTy = find;
   | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
   |
   = note: for more information, see https://github.com/rust-lang/rust/issues/54912

error[E0658]: naming constants with `_` is unstable
 --> /home/michael/.cargo/registry/src/github.com-1ecc6299db9ec823/memchr-2.4.1/src/memmem/prefilter/x86/sse.rs:9:1
  |
9 | const _: PrefilterFnTy = find;
  | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  |
  = note: for more information, see https://github.com/rust-lang/rust/issues/54912

error[E0658]: non exhaustive is an experimental feature
   --> /home/michael/.cargo/registry/src/github.com-1ecc6299db9ec823/memchr-2.4.1/src/memmem/prefilter/mod.rs:152:1
    |
152 | #[non_exhaustive]
    | ^^^^^^^^^^^^^^^^^
    |
    = note: for more information, see https://github.com/rust-lang/rust/issues/44109

error: aborting due to 3 previous errors

Your Environment

This was tested against ffe447a using Rust 1.36.0 on Linux.

@epage
Copy link
Collaborator

epage commented Feb 1, 2023

Dependencies do not affect MSRV so long as the minimum version still works.

@epage epage closed this as not planned Won't fix, can't repro, duplicate, stale Feb 1, 2023
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

No branches or pull requests

2 participants