2025-01-02 18:31:40 +01:00
|
|
|
// Test that we do not attempt to create dyn-incompatible trait objects in const eval.
|
|
|
|
|
|
|
|
|
|
trait Qux {
|
|
|
|
|
fn bar();
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
static FOO: &(dyn Qux + Sync) = "desc";
|
2025-04-05 19:19:56 +03:00
|
|
|
//~^ ERROR the trait `Qux` is not dyn compatible
|
|
|
|
|
//~| ERROR the trait `Qux` is not dyn compatible
|
2025-01-02 18:31:40 +01:00
|
|
|
|
|
|
|
|
fn main() {}
|