2024-11-18 10:45:26 -08:00
|
|
|
//@ reference: attributes.diagnostic.on_unimplemented.intro
|
|
|
|
|
|
2024-10-14 14:18:13 -04:00
|
|
|
#![feature(negative_bounds)]
|
|
|
|
|
|
|
|
|
|
#[diagnostic::on_unimplemented(message = "this ain't fooing")]
|
|
|
|
|
trait Foo {}
|
|
|
|
|
struct NotFoo;
|
|
|
|
|
|
|
|
|
|
fn hello() -> impl !Foo {
|
|
|
|
|
//~^ ERROR the trait bound `NotFoo: !Foo` is not satisfied
|
|
|
|
|
NotFoo
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
fn main() {}
|