-
Notifications
You must be signed in to change notification settings - Fork 966
api: Add a test for trait dyn compatibility #3829
Copy link
Copy link
Closed
Labels
1.0Issues and PRs required or helping to stabilize the APIIssues and PRs required or helping to stabilize the APIC-hashesPRs modifying the hashes cratePRs modifying the hashes crateC-primitivesC-unitsPRs modifying the units cratePRs modifying the units crate
Description
dyn compatibility (formerly object safety) can be verified by using
struct Foo {
// If this compiles then `Trait` is dyn compatible.
p: Box<dyn Trait>,
}We should add such a test to any api test file (e.g. units/tests/api.rs).
Before closing this issue it must be done for all traits in all leaf crates
-
units(units: Test for dyn compatibility #3926) [ ]io(MakeReadandBufReaddyn compatible #3917)-
hashes(done as part of hashes: Add an API test module #3927) -
primitives(api.rsfile still todo: primitives: Add an API test module #3928)
ref:
Reactions are currently unavailable
Metadata
Metadata
Assignees
Labels
1.0Issues and PRs required or helping to stabilize the APIIssues and PRs required or helping to stabilize the APIC-hashesPRs modifying the hashes cratePRs modifying the hashes crateC-primitivesC-unitsPRs modifying the units cratePRs modifying the units crate