@@ -451,99 +451,99 @@ impl Value {
451451 pub ( crate ) fn generic_bin_into < T , E > (
452452 self ,
453453 other : Self ,
454- n : impl FnOnce ( Array < f64 > , Array < f64 > ) -> Result < T , E > ,
455- _b : impl FnOnce ( Array < u8 > , Array < u8 > ) -> Result < T , E > ,
456- _co : impl FnOnce ( Array < Complex > , Array < Complex > ) -> Result < T , E > ,
457- ch : impl FnOnce ( Array < char > , Array < char > ) -> Result < T , E > ,
458- f : impl FnOnce ( Array < Boxed > , Array < Boxed > ) -> Result < T , E > ,
454+ num : impl FnOnce ( Array < f64 > , Array < f64 > ) -> Result < T , E > ,
455+ byte : impl FnOnce ( Array < u8 > , Array < u8 > ) -> Result < T , E > ,
456+ comp : impl FnOnce ( Array < Complex > , Array < Complex > ) -> Result < T , E > ,
457+ char : impl FnOnce ( Array < char > , Array < char > ) -> Result < T , E > ,
458+ bx : impl FnOnce ( Array < Boxed > , Array < Boxed > ) -> Result < T , E > ,
459459 err : impl FnOnce ( Self , Self ) -> E ,
460460 ) -> Result < T , E > {
461461 match ( self , other) {
462- ( Self :: Num ( a) , Self :: Num ( b) ) => n ( a, b) ,
463- ( Self :: Byte ( a) , Self :: Byte ( b) ) => _b ( a, b) ,
464- ( Self :: Byte ( a) , Self :: Num ( b) ) => n ( a. convert ( ) , b) ,
465- ( Self :: Num ( a) , Self :: Byte ( b) ) => n ( a, b. convert ( ) ) ,
466- ( Self :: Complex ( a) , Self :: Complex ( b) ) => _co ( a, b) ,
467- ( Self :: Complex ( a) , Self :: Num ( b) ) => _co ( a, b. convert ( ) ) ,
468- ( Self :: Num ( a) , Self :: Complex ( b) ) => _co ( a. convert ( ) , b) ,
469- ( Self :: Complex ( a) , Self :: Byte ( b) ) => _co ( a, b. convert ( ) ) ,
470- ( Self :: Byte ( a) , Self :: Complex ( b) ) => _co ( a. convert ( ) , b) ,
471- ( Self :: Char ( a) , Self :: Char ( b) ) => ch ( a, b) ,
472- ( Self :: Box ( a) , Self :: Box ( b) ) => f ( a, b) ,
473- ( Self :: Box ( a) , b) => f ( a, b. coerce_to_boxes ( ) ) ,
474- ( a, Self :: Box ( b) ) => f ( a. coerce_to_boxes ( ) , b) ,
462+ ( Self :: Num ( a) , Self :: Num ( b) ) => num ( a, b) ,
463+ ( Self :: Byte ( a) , Self :: Byte ( b) ) => byte ( a, b) ,
464+ ( Self :: Byte ( a) , Self :: Num ( b) ) => num ( a. convert ( ) , b) ,
465+ ( Self :: Num ( a) , Self :: Byte ( b) ) => num ( a, b. convert ( ) ) ,
466+ ( Self :: Complex ( a) , Self :: Complex ( b) ) => comp ( a, b) ,
467+ ( Self :: Complex ( a) , Self :: Num ( b) ) => comp ( a, b. convert ( ) ) ,
468+ ( Self :: Num ( a) , Self :: Complex ( b) ) => comp ( a. convert ( ) , b) ,
469+ ( Self :: Complex ( a) , Self :: Byte ( b) ) => comp ( a, b. convert ( ) ) ,
470+ ( Self :: Byte ( a) , Self :: Complex ( b) ) => comp ( a. convert ( ) , b) ,
471+ ( Self :: Char ( a) , Self :: Char ( b) ) => char ( a, b) ,
472+ ( Self :: Box ( a) , Self :: Box ( b) ) => bx ( a, b) ,
473+ ( Self :: Box ( a) , b) => bx ( a, b. coerce_to_boxes ( ) ) ,
474+ ( a, Self :: Box ( b) ) => bx ( a. coerce_to_boxes ( ) , b) ,
475475 ( a, b) => Err ( err ( a, b) ) ,
476476 }
477477 }
478478 #[ allow( clippy:: too_many_arguments) ]
479479 pub ( crate ) fn generic_bin_ref < T , E > (
480480 & self ,
481481 other : & Self ,
482- n : impl FnOnce ( & Array < f64 > , & Array < f64 > ) -> Result < T , E > ,
483- _b : impl FnOnce ( & Array < u8 > , & Array < u8 > ) -> Result < T , E > ,
484- _co : impl FnOnce ( & Array < Complex > , & Array < Complex > ) -> Result < T , E > ,
485- ch : impl FnOnce ( & Array < char > , & Array < char > ) -> Result < T , E > ,
486- f : impl FnOnce ( & Array < Boxed > , & Array < Boxed > ) -> Result < T , E > ,
482+ num : impl FnOnce ( & Array < f64 > , & Array < f64 > ) -> Result < T , E > ,
483+ byte : impl FnOnce ( & Array < u8 > , & Array < u8 > ) -> Result < T , E > ,
484+ comp : impl FnOnce ( & Array < Complex > , & Array < Complex > ) -> Result < T , E > ,
485+ char : impl FnOnce ( & Array < char > , & Array < char > ) -> Result < T , E > ,
486+ bx : impl FnOnce ( & Array < Boxed > , & Array < Boxed > ) -> Result < T , E > ,
487487 err : impl FnOnce ( & Self , & Self ) -> E ,
488488 ) -> Result < T , E > {
489489 match ( self , other) {
490- ( Self :: Num ( a) , Self :: Num ( b) ) => n ( a, b) ,
491- ( Self :: Byte ( a) , Self :: Byte ( b) ) => _b ( a, b) ,
492- ( Self :: Byte ( a) , Self :: Num ( b) ) => n ( & a. convert_ref ( ) , b) ,
493- ( Self :: Num ( a) , Self :: Byte ( b) ) => n ( a, & b. convert_ref ( ) ) ,
494- ( Self :: Complex ( a) , Self :: Complex ( b) ) => _co ( a, b) ,
495- ( Self :: Complex ( a) , Self :: Num ( b) ) => _co ( a, & b. convert_ref ( ) ) ,
496- ( Self :: Num ( a) , Self :: Complex ( b) ) => _co ( & a. convert_ref ( ) , b) ,
497- ( Self :: Complex ( a) , Self :: Byte ( b) ) => _co ( a, & b. convert_ref ( ) ) ,
498- ( Self :: Byte ( a) , Self :: Complex ( b) ) => _co ( & a. convert_ref ( ) , b) ,
499- ( Self :: Char ( a) , Self :: Char ( b) ) => ch ( a, b) ,
500- ( Self :: Box ( a) , Self :: Box ( b) ) => f ( a, b) ,
501- ( Self :: Box ( a) , b) => f ( a, & b. coerce_as_boxes ( ) ) ,
502- ( a, Self :: Box ( b) ) => f ( & a. coerce_as_boxes ( ) , b) ,
490+ ( Self :: Num ( a) , Self :: Num ( b) ) => num ( a, b) ,
491+ ( Self :: Byte ( a) , Self :: Byte ( b) ) => byte ( a, b) ,
492+ ( Self :: Byte ( a) , Self :: Num ( b) ) => num ( & a. convert_ref ( ) , b) ,
493+ ( Self :: Num ( a) , Self :: Byte ( b) ) => num ( a, & b. convert_ref ( ) ) ,
494+ ( Self :: Complex ( a) , Self :: Complex ( b) ) => comp ( a, b) ,
495+ ( Self :: Complex ( a) , Self :: Num ( b) ) => comp ( a, & b. convert_ref ( ) ) ,
496+ ( Self :: Num ( a) , Self :: Complex ( b) ) => comp ( & a. convert_ref ( ) , b) ,
497+ ( Self :: Complex ( a) , Self :: Byte ( b) ) => comp ( a, & b. convert_ref ( ) ) ,
498+ ( Self :: Byte ( a) , Self :: Complex ( b) ) => comp ( & a. convert_ref ( ) , b) ,
499+ ( Self :: Char ( a) , Self :: Char ( b) ) => char ( a, b) ,
500+ ( Self :: Box ( a) , Self :: Box ( b) ) => bx ( a, b) ,
501+ ( Self :: Box ( a) , b) => bx ( a, & b. coerce_as_boxes ( ) ) ,
502+ ( a, Self :: Box ( b) ) => bx ( & a. coerce_as_boxes ( ) , b) ,
503503 ( a, b) => Err ( err ( a, b) ) ,
504504 }
505505 }
506506 #[ allow( clippy:: too_many_arguments) ]
507507 pub ( crate ) fn generic_bin_mut < T , E > (
508508 & mut self ,
509509 other : Self ,
510- n : impl FnOnce ( & mut Array < f64 > , Array < f64 > ) -> Result < T , E > ,
511- _b : impl FnOnce ( & mut Array < u8 > , Array < u8 > ) -> Result < T , E > ,
512- _co : impl FnOnce ( & mut Array < Complex > , Array < Complex > ) -> Result < T , E > ,
513- ch : impl FnOnce ( & mut Array < char > , Array < char > ) -> Result < T , E > ,
514- f : impl FnOnce ( & mut Array < Boxed > , Array < Boxed > ) -> Result < T , E > ,
510+ num : impl FnOnce ( & mut Array < f64 > , Array < f64 > ) -> Result < T , E > ,
511+ byte : impl FnOnce ( & mut Array < u8 > , Array < u8 > ) -> Result < T , E > ,
512+ comp : impl FnOnce ( & mut Array < Complex > , Array < Complex > ) -> Result < T , E > ,
513+ char : impl FnOnce ( & mut Array < char > , Array < char > ) -> Result < T , E > ,
514+ bx : impl FnOnce ( & mut Array < Boxed > , Array < Boxed > ) -> Result < T , E > ,
515515 err : impl FnOnce ( & Self , & Self ) -> E ,
516516 ) -> Result < T , E > {
517517 match ( & mut * self , other) {
518- ( Self :: Num ( a) , Self :: Num ( b) ) => n ( a, b) ,
519- ( Self :: Byte ( a) , Self :: Byte ( b) ) => _b ( a, b) ,
518+ ( Self :: Num ( a) , Self :: Num ( b) ) => num ( a, b) ,
519+ ( Self :: Byte ( a) , Self :: Byte ( b) ) => byte ( a, b) ,
520520 ( Self :: Byte ( a) , Self :: Num ( b) ) => {
521521 let mut a_num = a. convert_ref ( ) ;
522- let res = n ( & mut a_num, b) ;
522+ let res = num ( & mut a_num, b) ;
523523 * self = a_num. into ( ) ;
524524 res
525525 }
526- ( Self :: Num ( a) , Self :: Byte ( b) ) => n ( a, b. convert_ref ( ) ) ,
527- ( Self :: Complex ( a) , Self :: Complex ( b) ) => _co ( a, b) ,
528- ( Self :: Complex ( a) , Self :: Num ( b) ) => _co ( a, b. convert_ref ( ) ) ,
526+ ( Self :: Num ( a) , Self :: Byte ( b) ) => num ( a, b. convert_ref ( ) ) ,
527+ ( Self :: Complex ( a) , Self :: Complex ( b) ) => comp ( a, b) ,
528+ ( Self :: Complex ( a) , Self :: Num ( b) ) => comp ( a, b. convert_ref ( ) ) ,
529529 ( Self :: Num ( a) , Self :: Complex ( b) ) => {
530530 let mut a_comp = a. convert_ref ( ) ;
531- let res = _co ( & mut a_comp, b) ;
531+ let res = comp ( & mut a_comp, b) ;
532532 * self = a_comp. into ( ) ;
533533 res
534534 }
535- ( Self :: Complex ( a) , Self :: Byte ( b) ) => _co ( a, b. convert_ref ( ) ) ,
535+ ( Self :: Complex ( a) , Self :: Byte ( b) ) => comp ( a, b. convert_ref ( ) ) ,
536536 ( Self :: Byte ( a) , Self :: Complex ( b) ) => {
537537 let mut a_comp = a. convert_ref ( ) ;
538- let res = _co ( & mut a_comp, b) ;
538+ let res = comp ( & mut a_comp, b) ;
539539 * self = a_comp. into ( ) ;
540540 res
541541 }
542- ( Self :: Char ( a) , Self :: Char ( b) ) => ch ( a, b) ,
543- ( Self :: Box ( a) , b) => f ( a, b. coerce_to_boxes ( ) ) ,
542+ ( Self :: Char ( a) , Self :: Char ( b) ) => char ( a, b) ,
543+ ( Self :: Box ( a) , b) => bx ( a, b. coerce_to_boxes ( ) ) ,
544544 ( a, Self :: Box ( b) ) => {
545545 let mut a_box = take ( a) . coerce_to_boxes ( ) ;
546- let res = f ( & mut a_box, b) ;
546+ let res = bx ( & mut a_box, b) ;
547547 * self = a_box. into ( ) ;
548548 res
549549 }
0 commit comments