From ecc7ae84db4a4e19367ce8fec88bbcd4be0ce75a Mon Sep 17 00:00:00 2001 From: David Tolnay Date: Sat, 10 Aug 2024 21:36:19 -0700 Subject: [PATCH] Align iterator type name with method name in Fields::members --- src/data.rs | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/src/data.rs b/src/data.rs index 6995d04488..3d1e61fc99 100644 --- a/src/data.rs +++ b/src/data.rs @@ -110,12 +110,12 @@ impl Fields { /// variant's fields uniformly. pub fn members(&self) -> impl Iterator + '_ { #[derive(Clone)] - struct IterMember<'a> { + struct Members<'a> { iter: punctuated::Iter<'a, Field>, unnamed_counter: u32, } - impl<'a> Iterator for IterMember<'a> { + impl<'a> Iterator for Members<'a> { type Item = Member; fn next(&mut self) -> Option { @@ -140,7 +140,7 @@ impl Fields { } } - IterMember { + Members { iter: self.iter(), unnamed_counter: 0, }