@@ -360,7 +360,7 @@ pub(crate) fn tool_fn_item(attr: TokenStream, mut input_fn: ItemFn) -> syn::Resu
360360 // async fn #tool_tool_call(context: rmcp::handler::server::tool::ToolCallContext<'_, Self>)
361361 // -> std::result::Result<rmcp::model::CallToolResult, rmcp::Error>
362362 //
363- // and the block part shoule be like:
363+ // and the block part should be like:
364364 // {
365365 // use rmcp::handler::server::tool::*;
366366 // let (t0, context) = <T0>::from_tool_call_context_part(context)?;
@@ -383,8 +383,8 @@ pub(crate) fn tool_fn_item(attr: TokenStream, mut input_fn: ItemFn) -> syn::Resu
383383 // for receiver type, name it as __rmcp_tool_receiver
384384 let is_async = input_fn. sig . asyncness . is_some ( ) ;
385385 let receiver_ident = || Ident :: new ( "__rmcp_tool_receiver" , proc_macro2:: Span :: call_site ( ) ) ;
386- // generate the extraction part for trival args
387- let trival_args = input_fn
386+ // generate the extraction part for trivial args
387+ let trivial_args = input_fn
388388 . sig
389389 . inputs
390390 . iter ( )
@@ -413,8 +413,8 @@ pub(crate) fn tool_fn_item(attr: TokenStream, mut input_fn: ItemFn) -> syn::Resu
413413 Some ( line)
414414 }
415415 } ) ;
416- let trival_argrextraction_part = quote ! {
417- #( #trival_args ) *
416+ let trivial_argrextraction_part = quote ! {
417+ #( #trivial_args ) *
418418 } ;
419419 let processed_argrextraction_part = match & mut tool_macro_attrs. params {
420420 ToolParams :: Aggregated { rust_type } => {
@@ -441,7 +441,7 @@ pub(crate) fn tool_fn_item(attr: TokenStream, mut input_fn: ItemFn) -> syn::Resu
441441 }
442442 } ;
443443 // generate the execution part
444- // has reveiver ?
444+ // has receiver ?
445445 let params = & input_fn
446446 . sig
447447 . inputs
@@ -487,7 +487,7 @@ pub(crate) fn tool_fn_item(attr: TokenStream, mut input_fn: ItemFn) -> syn::Resu
487487 #raw_fn_vis async fn #tool_call_fn_ident( context: rmcp:: handler:: server:: tool:: ToolCallContext <' _, Self >)
488488 -> std:: result:: Result <rmcp:: model:: CallToolResult , rmcp:: Error > {
489489 use rmcp:: handler:: server:: tool:: * ;
490- #trival_argrextraction_part
490+ #trivial_argrextraction_part
491491 #processed_argrextraction_part
492492 #call
493493 }
0 commit comments