Port #[rustc_coinductive] to the new attribute system

This commit is contained in:
Pavel Grigorenko
2025-06-24 00:27:30 +03:00
parent adb325fc16
commit 6f8e92d5aa
7 changed files with 17 additions and 5 deletions

View File

@@ -75,3 +75,10 @@ impl<S: Stage> NoArgsAttributeParser<S> for DoNotImplementViaObjectParser {
const ON_DUPLICATE: OnDuplicate<S> = OnDuplicate::Error;
const CREATE: fn(Span) -> AttributeKind = AttributeKind::DoNotImplementViaObject;
}
pub(crate) struct CoinductiveParser;
impl<S: Stage> NoArgsAttributeParser<S> for CoinductiveParser {
const PATH: &[Symbol] = &[sym::rustc_coinductive];
const ON_DUPLICATE: OnDuplicate<S> = OnDuplicate::Error;
const CREATE: fn(Span) -> AttributeKind = AttributeKind::Coinductive;
}