From bcc4469c2b4d75bd52f23d404e9c4b3561372b2a Mon Sep 17 00:00:00 2001 From: "Christopher B. Speir" Date: Tue, 23 Apr 2024 14:38:29 -0500 Subject: [PATCH] Add diagnostic item for std::iter::Enumerate --- compiler/rustc_span/src/symbol.rs | 1 + library/core/src/iter/adapters/enumerate.rs | 1 + 2 files changed, 2 insertions(+) diff --git a/compiler/rustc_span/src/symbol.rs b/compiler/rustc_span/src/symbol.rs index 8abf42e2c13..99591b5e144 100644 --- a/compiler/rustc_span/src/symbol.rs +++ b/compiler/rustc_span/src/symbol.rs @@ -192,6 +192,7 @@ Duration, Encodable, Encoder, + Enumerate, Eq, Equal, Err, diff --git a/library/core/src/iter/adapters/enumerate.rs b/library/core/src/iter/adapters/enumerate.rs index ef46040f0a7..7adbabf69e4 100644 --- a/library/core/src/iter/adapters/enumerate.rs +++ b/library/core/src/iter/adapters/enumerate.rs @@ -15,6 +15,7 @@ #[derive(Clone, Debug)] #[must_use = "iterators are lazy and do nothing unless consumed"] #[stable(feature = "rust1", since = "1.0.0")] +#[cfg_attr(not(test), rustc_diagnostic_item = "Enumerate")] pub struct Enumerate { iter: I, count: usize,