Skip to content

1.95 beta regression affecting old versions of bitvec: "... is not dyn compatible" #153731

@theemathas

Description

@theemathas

Regression found in the 1.95.0 beta crater run.

[INFO] [stdout] error[E0038]: the trait `order::BitOrder` is not dyn compatible
[INFO] [stdout]    --> /opt/rustwide/cargo-home/registry/src/index.crates.io-1949cf8c6b5b557f/bitvec-0.17.4/src/lib.rs:124:20
[INFO] [stdout]     |
[INFO] [stdout] 124 |     pub type Cursor = crate::order::BitOrder;
[INFO] [stdout]     |                       ^^^^^^^^^^^^^^^^^^^^^^ `order::BitOrder` is not dyn compatible
[INFO] [stdout]     |
[INFO] [stdout] note: for a trait to be dyn compatible it needs to allow building a vtable
[INFO] [stdout]       for more information, visit <https://doc.rust-lang.org/reference/items/traits.html#dyn-compatibility>
[INFO] [stdout]    --> /opt/rustwide/cargo-home/registry/src/index.crates.io-1949cf8c6b5b557f/bitvec-0.17.4/src/order.rs:45:8
[INFO] [stdout]     |
[INFO] [stdout]  43 | pub trait BitOrder {
[INFO] [stdout]     |           -------- this trait is not dyn compatible...
[INFO] [stdout]  44 |     /// Name of the ordering type, for use in text display.
[INFO] [stdout]  45 |     const TYPENAME: &'static str;
[INFO] [stdout]     |           ^^^^^^^^ ...because it contains associated const `TYPENAME`
[INFO] [stdout]     = help: consider moving `TYPENAME` to another trait
[INFO] [stdout]     = help: the following types implement `order::BitOrder`:
[INFO] [stdout]               order::Msb0
[INFO] [stdout]               order::Lsb0
[INFO] [stdout]             consider defining an enum where each variant holds one of these types,
[INFO] [stdout]             implementing `order::BitOrder` for this new enum and using it instead
[INFO] [stdout]     = note: `order::BitOrder` may be implemented in other crates; if you want to support your users passing their own types here, you can't refer to a specific type

Affects 254 dependents of bitvec versions 0.17.2-0.17.4

[INFO] [stdout] error[E0038]: the trait `tutel_core::Transform` is not dyn compatible
[INFO] [stdout]   --> src/lib.rs:6:33
[INFO] [stdout]    |
[INFO] [stdout]  6 | pub type DynTransform = Box<dyn Transform>;
[INFO] [stdout]    |                                 ^^^^^^^^^ `tutel_core::Transform` is not dyn compatible
[INFO] [stdout]    |
[INFO] [stdout] note: for a trait to be dyn compatible it needs to allow building a vtable
[INFO] [stdout]       for more information, visit <https://doc.rust-lang.org/reference/items/traits.html#dyn-compatibility>
[INFO] [stdout]   --> tutel-core/src/lib.rs:44:11
[INFO] [stdout]    |
[INFO] [stdout] 44 |     const NAME: &'static str;
[INFO] [stdout]    |           ^^^^ the trait is not dyn compatible because it contains associated const `NAME`
[INFO] [stdout] 
[INFO] [stdout] 
[INFO] [stdout] For more information about this error, try `rustc --explain E0038`.
[INFO] [stdout] error[E0038]: the trait `AeadCore` is not dyn compatible
[INFO] [stdout]    --> src/lib.rs:499:35
[INFO] [stdout]     |
[INFO] [stdout] 499 |     type DynAeadInOut<N, T> = dyn AeadInOut<NonceSize = N, TagSize = T>;
[INFO] [stdout]     |                                   ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ `AeadCore` is not dyn compatible
[INFO] [stdout]     |
[INFO] [stdout] note: for a trait to be dyn compatible it needs to allow building a vtable
[INFO] [stdout]       for more information, visit <https://doc.rust-lang.org/reference/items/traits.html#dyn-compatibility>
[INFO] [stdout]    --> src/lib.rs:132:11
[INFO] [stdout]     |
[INFO] [stdout] 124 | pub trait AeadCore {
[INFO] [stdout]     |           -------- this trait is not dyn compatible...
[INFO] [stdout] ...
[INFO] [stdout] 132 |     const TAG_POSITION: TagPosition;
[INFO] [stdout]     |           ^^^^^^^^^^^^ ...because it contains associated const `TAG_POSITION`
[INFO] [stdout]     = help: consider moving `TAG_POSITION` to another trait
[INFO] [stdout] 
[INFO] [stdout] 
[INFO] [stdout] For more information about this error, try `rustc --explain E0038`.

Metadata

Metadata

Assignees

Labels

A-dyn-compatibilityArea: Dyn compatibility (formerly: object safety)A-dyn-traitArea: trait objects, vtable layoutC-bugCategory: This is a bug.P-highHigh priorityS-has-bisectionStatus: A bisection has been found for this issueS-has-mcveStatus: A Minimal Complete and Verifiable Example has been found for this issueT-typesRelevant to the types team, which will review and decide on the PR/issue.regression-from-stable-to-betaPerformance or correctness regression from stable to beta.

Type

No type
No fields configured for issues without a type.

Projects

No projects

Relationships

None yet

Development

No branches or pull requests

Issue actions