2024-11-18 10:45:26 -08:00
|
|
|
//@ reference: attributes.diagnostic.on_unimplemented.intro
|
|
|
|
|
//@ reference: attributes.diagnostic.on_unimplemented.keys
|
2025-04-05 19:19:56 +03:00
|
|
|
//@ dont-require-annotations: NOTE
|
|
|
|
|
|
2024-09-09 01:17:49 +02:00
|
|
|
#[diagnostic::on_unimplemented(message = "my message", label = "my label", note = "my note")]
|
|
|
|
|
pub trait ProviderLt {}
|
|
|
|
|
|
|
|
|
|
pub trait ProviderExt {
|
|
|
|
|
fn request<R>(&self) {
|
|
|
|
|
todo!()
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
impl<T: ?Sized + ProviderLt> ProviderExt for T {}
|
|
|
|
|
|
|
|
|
|
struct B;
|
|
|
|
|
|
|
|
|
|
fn main() {
|
|
|
|
|
B.request();
|
2025-04-05 19:19:56 +03:00
|
|
|
//~^ ERROR my message [E0599]
|
2025-04-05 19:19:56 +03:00
|
|
|
//~| NOTE my label
|
|
|
|
|
//~| NOTE my note
|
2024-09-09 01:17:49 +02:00
|
|
|
}
|