Add diagnostic items

This commit is contained in:
Cameron Steffen 2021-02-26 21:23:42 -06:00
parent 4a6e67ead7
commit eada4d1c45
6 changed files with 10 additions and 0 deletions

View File

@ -126,6 +126,9 @@ symbols! {
Argument,
ArgumentV1,
Arguments,
BTreeMap,
BTreeSet,
BinaryHeap,
C,
CString,
Center,
@ -163,6 +166,7 @@ symbols! {
Iterator,
Layout,
Left,
LinkedList,
LintPass,
None,
Ok,
@ -1258,6 +1262,7 @@ symbols! {
variant_count,
vec,
vec_type,
vecdeque_type,
version,
vis,
visible_private_types,

View File

@ -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>,
}

View File

@ -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,

View File

@ -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, ()>,
}

View File

@ -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>>>,

View File

@ -310,6 +310,7 @@ mod cache_aligned;
/// println!("{}", recv.recv().unwrap()); // Received after 2 seconds
/// ```
#[stable(feature = "rust1", since = "1.0.0")]
#[cfg_attr(not(test), rustc_diagnostic_item = "Receiver")]
pub struct Receiver<T> {
inner: UnsafeCell<Flavor<T>>,
}