2022-10-28 12:32:34 -05:00
|
|
|
use std::fmt::Debug;
|
|
|
|
|
|
|
|
fn make_dyn_star() {
|
|
|
|
let i = 42usize;
|
|
|
|
let dyn_i: dyn* Debug = i as dyn* Debug;
|
|
|
|
//~^ ERROR casting `usize` as `dyn* Debug` is invalid
|
2023-03-11 15:18:45 -06:00
|
|
|
//~| ERROR `dyn*` trait objects are experimental
|
|
|
|
//~| ERROR `dyn*` trait objects are experimental
|
2022-10-28 12:32:34 -05:00
|
|
|
}
|
|
|
|
|
|
|
|
fn main() {
|
|
|
|
make_dyn_star();
|
|
|
|
}
|