@@ -254,17 +254,17 @@ macro_rules! define_client_side {
254254 $( impl $name {
255255 $( pub ( crate ) fn $method( $( $arg: $arg_ty) ,* ) $( -> $ret_ty) * {
256256 Bridge :: with( |bridge| {
257- let mut b = bridge. cached_buffer. take( ) ;
257+ let mut buf = bridge. cached_buffer. take( ) ;
258258
259- b . clear( ) ;
260- api_tags:: Method :: $name( api_tags:: $name:: $method) . encode( & mut b , & mut ( ) ) ;
261- reverse_encode!( b ; $( $arg) ,* ) ;
259+ buf . clear( ) ;
260+ api_tags:: Method :: $name( api_tags:: $name:: $method) . encode( & mut buf , & mut ( ) ) ;
261+ reverse_encode!( buf ; $( $arg) ,* ) ;
262262
263- b = bridge. dispatch. call( b ) ;
263+ buf = bridge. dispatch. call( buf ) ;
264264
265- let r = Result :: <_, PanicMessage >:: decode( & mut & b [ ..] , & mut ( ) ) ;
265+ let r = Result :: <_, PanicMessage >:: decode( & mut & buf [ ..] , & mut ( ) ) ;
266266
267- bridge. cached_buffer = b ;
267+ bridge. cached_buffer = buf ;
268268
269269 r. unwrap_or_else( |e| panic:: resume_unwind( e. into( ) ) )
270270 } )
@@ -383,20 +383,20 @@ fn run_client<A: for<'a, 's> DecodeMut<'a, 's, ()>, R: Encode<()>>(
383383 f : impl FnOnce ( A ) -> R ,
384384) -> Buffer {
385385 // The initial `cached_buffer` contains the input.
386- let mut b = bridge. cached_buffer . take ( ) ;
386+ let mut buf = bridge. cached_buffer . take ( ) ;
387387
388388 panic:: catch_unwind ( panic:: AssertUnwindSafe ( || {
389389 bridge. enter ( || {
390- let reader = & mut & b [ ..] ;
390+ let reader = & mut & buf [ ..] ;
391391 let input = A :: decode ( reader, & mut ( ) ) ;
392392
393393 // Put the `cached_buffer` back in the `Bridge`, for requests.
394- Bridge :: with ( |bridge| bridge. cached_buffer = b . take ( ) ) ;
394+ Bridge :: with ( |bridge| bridge. cached_buffer = buf . take ( ) ) ;
395395
396396 let output = f ( input) ;
397397
398398 // Take the `cached_buffer` back out, for the output value.
399- b = Bridge :: with ( |bridge| bridge. cached_buffer . take ( ) ) ;
399+ buf = Bridge :: with ( |bridge| bridge. cached_buffer . take ( ) ) ;
400400
401401 // HACK(eddyb) Separate encoding a success value (`Ok(output)`)
402402 // from encoding a panic (`Err(e: PanicMessage)`) to avoid
@@ -407,16 +407,16 @@ fn run_client<A: for<'a, 's> DecodeMut<'a, 's, ()>, R: Encode<()>>(
407407 // this is defensively trying to avoid any accidental panicking
408408 // reaching the `extern "C"` (which should `abort` but might not
409409 // at the moment, so this is also potentially preventing UB).
410- b . clear ( ) ;
411- Ok :: < _ , ( ) > ( output) . encode ( & mut b , & mut ( ) ) ;
410+ buf . clear ( ) ;
411+ Ok :: < _ , ( ) > ( output) . encode ( & mut buf , & mut ( ) ) ;
412412 } )
413413 } ) )
414414 . map_err ( PanicMessage :: from)
415415 . unwrap_or_else ( |e| {
416- b . clear ( ) ;
417- Err :: < ( ) , _ > ( e) . encode ( & mut b , & mut ( ) ) ;
416+ buf . clear ( ) ;
417+ Err :: < ( ) , _ > ( e) . encode ( & mut buf , & mut ( ) ) ;
418418 } ) ;
419- b
419+ buf
420420}
421421
422422impl Client < fn ( crate :: TokenStream ) -> crate :: TokenStream > {
0 commit comments