diff options
| author | Maybe Waffle <waffle.lapkin@gmail.com> | 2021-12-21 18:40:50 +0300 |
|---|---|---|
| committer | Maybe Waffle <waffle.lapkin@gmail.com> | 2022-01-09 12:21:23 +0300 |
| commit | 5ab40c8f99607a28441c921690b4498f0186c701 (patch) | |
| tree | fbd2199c8366c4aa602e15ecaab3a665342dbfed /compiler/rustc_feature/src | |
| parent | 02fe61b381c2dedc0071e1aacfbe91e0bad1f656 (diff) | |
| download | rust-5ab40c8f99607a28441c921690b4498f0186c701.tar.gz rust-5ab40c8f99607a28441c921690b4498f0186c701.zip | |
Implement `#[rustc_must_implement_one_of]` attribute
Diffstat (limited to 'compiler/rustc_feature/src')
| -rw-r--r-- | compiler/rustc_feature/src/builtin_attrs.rs | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/compiler/rustc_feature/src/builtin_attrs.rs b/compiler/rustc_feature/src/builtin_attrs.rs index f25b2d8f566..6f119d5ab88 100644 --- a/compiler/rustc_feature/src/builtin_attrs.rs +++ b/compiler/rustc_feature/src/builtin_attrs.rs @@ -677,6 +677,12 @@ pub const BUILTIN_ATTRIBUTES: &[BuiltinAttribute] = &[ "the `#[rustc_skip_array_during_method_dispatch]` attribute is used to exclude a trait \ from method dispatch when the receiver is an array, for compatibility in editions < 2021." ), + rustc_attr!( + rustc_must_implement_one_of, Normal, template!(List: "method1, method2, ..."), ErrorFollowing, + "the `#[rustc_must_implement_one_of]` attribute is used to change minimal complete \ + definition of a trait, it's currently in experimental form and should be changed before \ + being exposed outside of the std" + ), // ========================================================================== // Internal attributes, Testing: |
