1
0
mirror of https://github.com/danog/strum.git synced 2024-11-29 20:18:58 +01:00

Add doc comment to struct generated by EnumIter

This commit is contained in:
Peter Glotfelty 2022-01-08 12:18:09 -08:00
parent 4f6a556b9a
commit 8febdbba1a

View File

@ -67,7 +67,7 @@ pub fn enum_iter_inner(ast: &DeriveInput) -> syn::Result<TokenStream> {
let iter_name = syn::parse_str::<Ident>(&format!("{}Iter", name)).unwrap();
Ok(quote! {
#[allow(missing_docs)]
#[doc = "An iterator over the variants of [Self]"]
#vis struct #iter_name #ty_generics {
idx: usize,
back_idx: usize,