diff --git a/extendr-macros/src/wrappers.rs b/extendr-macros/src/wrappers.rs index a49b46b341..5a9021042e 100644 --- a/extendr-macros/src/wrappers.rs +++ b/extendr-macros/src/wrappers.rs @@ -49,7 +49,7 @@ pub fn make_function_wrappers( let call_name = if has_self { let is_mut = match inputs.iter().next() { - Some(FnArg::Receiver(ref reciever)) => reciever.mutability.is_some(), + Some(FnArg::Receiver(ref receiver)) => receiver.mutability.is_some(), _ => false, }; if is_mut { @@ -317,8 +317,8 @@ pub fn translate_formal(input: &FnArg, self_ty: Option<&syn::Type>) -> FnArg { parse_quote! { #pat : extendr_api::SEXP } } // &self / &mut self - FnArg::Receiver(ref reciever) => { - if !reciever.attrs.is_empty() || reciever.reference.is_none() { + FnArg::Receiver(ref receiver) => { + if !receiver.attrs.is_empty() || receiver.reference.is_none() { quote!(compile_error!("expected &self or &mut self")); } if self_ty.is_none() { @@ -352,8 +352,8 @@ fn translate_meta_arg(input: &mut FnArg, self_ty: Option<&syn::Type>) -> Expr { } } // &self - FnArg::Receiver(ref reciever) => { - if !reciever.attrs.is_empty() || reciever.reference.is_none() { + FnArg::Receiver(ref receiver) => { + if !receiver.attrs.is_empty() || receiver.reference.is_none() { panic!("expected &self or &mut self"); } if self_ty.is_none() {