mirror of
https://github.com/rust-lang/rust.git
synced 2025-05-14 02:49:40 +00:00
14 lines
248 B
Rust
14 lines
248 B
Rust
#![expect(incomplete_features)]
|
|
#![feature(dyn_star)]
|
|
|
|
trait A: B {}
|
|
trait B {}
|
|
impl A for usize {}
|
|
impl B for usize {}
|
|
|
|
fn main() {
|
|
let x: Box<dyn* A> = Box::new(1usize as dyn* A);
|
|
let y: Box<dyn* B> = x;
|
|
//~^ ERROR mismatched types
|
|
}
|