diff --git a/src/generate/generate_item.rs b/src/generate/generate_item.rs index 7c2affc..2e3e5ba 100644 --- a/src/generate/generate_item.rs +++ b/src/generate/generate_item.rs @@ -445,6 +445,9 @@ pub enum FnSelfArg { /// `self`. The function will consume self. TakeSelf, + /// `mut self`. The function will consume self. + MutTakeSelf, + /// `&self`. The function will take self by reference. RefSelf, @@ -460,6 +463,10 @@ impl FnSelfArg { Self::TakeSelf => { builder.ident_str("self"); } + Self::MutTakeSelf => { + builder.ident_str("mut"); + builder.ident_str("self"); + } Self::RefSelf => { builder.punct('&'); builder.ident_str("self");