diff options
| author | Cameron Steffen <cam.steffen94@gmail.com> | 2021-02-26 21:23:42 -0600 |
|---|---|---|
| committer | Cameron Steffen <cam.steffen94@gmail.com> | 2021-03-01 09:04:11 -0600 |
| commit | eada4d1c457f4421713cdabe7b57d70ae23a4278 (patch) | |
| tree | 1520ca82a6eaadf66e3bab3356c31c2d8e4b216c /library/alloc/src | |
| parent | 4a6e67ead7a29bca80b7f4a315ac666e2c6e2260 (diff) | |
| download | rust-eada4d1c457f4421713cdabe7b57d70ae23a4278.tar.gz rust-eada4d1c457f4421713cdabe7b57d70ae23a4278.zip | |
Add diagnostic items
Diffstat (limited to 'library/alloc/src')
| -rw-r--r-- | library/alloc/src/collections/binary_heap.rs | 1 | ||||
| -rw-r--r-- | library/alloc/src/collections/btree/map.rs | 1 | ||||
| -rw-r--r-- | library/alloc/src/collections/btree/set.rs | 1 | ||||
| -rw-r--r-- | library/alloc/src/collections/linked_list.rs | 1 |
4 files changed, 4 insertions, 0 deletions
diff --git a/library/alloc/src/collections/binary_heap.rs b/library/alloc/src/collections/binary_heap.rs index 33bd98d467c..4377780e15f 100644 --- a/library/alloc/src/collections/binary_heap.rs +++ b/library/alloc/src/collections/binary_heap.rs @@ -247,6 +247,7 @@ use super::SpecExtend; /// [peek]: BinaryHeap::peek /// [peek\_mut]: BinaryHeap::peek_mut #[stable(feature = "rust1", since = "1.0.0")] +#[cfg_attr(not(test), rustc_diagnostic_item = "BinaryHeap")] pub struct BinaryHeap<T> { data: Vec<T>, } diff --git a/library/alloc/src/collections/btree/map.rs b/library/alloc/src/collections/btree/map.rs index 3ba95d9f47a..783f88f026b 100644 --- a/library/alloc/src/collections/btree/map.rs +++ b/library/alloc/src/collections/btree/map.rs @@ -138,6 +138,7 @@ pub(super) const MIN_LEN: usize = node::MIN_LEN_AFTER_SPLIT; /// *stat += random_stat_buff(); /// ``` #[stable(feature = "rust1", since = "1.0.0")] +#[cfg_attr(not(test), rustc_diagnostic_item = "BTreeMap")] pub struct BTreeMap<K, V> { root: Option<Root<K, V>>, length: usize, diff --git a/library/alloc/src/collections/btree/set.rs b/library/alloc/src/collections/btree/set.rs index f2ec2774484..a331b8d8e4b 100644 --- a/library/alloc/src/collections/btree/set.rs +++ b/library/alloc/src/collections/btree/set.rs @@ -61,6 +61,7 @@ use super::Recover; /// ``` #[derive(Hash, PartialEq, Eq, Ord, PartialOrd)] #[stable(feature = "rust1", since = "1.0.0")] +#[cfg_attr(not(test), rustc_diagnostic_item = "BTreeSet")] pub struct BTreeSet<T> { map: BTreeMap<T, ()>, } diff --git a/library/alloc/src/collections/linked_list.rs b/library/alloc/src/collections/linked_list.rs index 397e774f1a0..a5481fd175e 100644 --- a/library/alloc/src/collections/linked_list.rs +++ b/library/alloc/src/collections/linked_list.rs @@ -35,6 +35,7 @@ mod tests; /// array-based containers are generally faster, /// more memory efficient, and make better use of CPU cache. #[stable(feature = "rust1", since = "1.0.0")] +#[cfg_attr(not(test), rustc_diagnostic_item = "LinkedList")] pub struct LinkedList<T> { head: Option<NonNull<Node<T>>>, tail: Option<NonNull<Node<T>>>, |
